WISDOMBAY

in4mation ... organized

How to Access System registry in VB .NET 2003

Page 2

Function deleteid(ByVal id As String)
RegKey.DeleteValue(id)
End Function

Function value(ByVal name As String, ByVal val As String)
RegKey.SetValue(name, val)
End Function

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Try
If TextBox1.Text = "" Then
MsgBox("Cannot be deleted")
Else
Call deleteregkey(TextBox1.Text)
End If
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
RadioButton1.Checked = True
End Sub

End Class

Google