c6a9cd69c2
* NEW: Add examples again. I hope correctly this time. git-svn-id: svn://localhost/gambas/trunk@6726 867c0c6c-44f3-4631-809d-bfa615b0a4ec
46 lines
914 B
Text
46 lines
914 B
Text
' Gambas class file
|
|
|
|
Public Sub btnCancel_Click()
|
|
|
|
Me.Close(True)
|
|
|
|
End
|
|
|
|
Public Sub btnConnect_Click()
|
|
|
|
modMain.$Host = txtServer.Text
|
|
modMain.$Password = txtPassword.Text
|
|
modMain.$Port = txtPort.Text
|
|
modMain.$User = txtUser.Text
|
|
Me.Close(False)
|
|
Catch
|
|
Message.Error(Error.Text)
|
|
|
|
End
|
|
|
|
Public Sub btnClear_Click()
|
|
|
|
txtPassword.Text = Null
|
|
txtPort.Text = Null
|
|
txtServer.Text = Null
|
|
txtUser.Text = Null
|
|
txtPassword.SetFocus()
|
|
|
|
End
|
|
|
|
Public Sub Form_Open()
|
|
|
|
txtServer.Text = Settings["/Conecction/Host", "localhost"]
|
|
txtUser.Text = Settings["/Conecction/User", "root"]
|
|
txtPort.Text = Settings["/Conecction/Port", "3306"]
|
|
txtPassword.SetFocus()
|
|
|
|
End
|
|
|
|
Public Sub Form_Close()
|
|
|
|
If txtServer.Text Then Settings["/Conecction/Host"] = txtServer.Text
|
|
If txtUser.Text Then Settings["/Conecction/User"] = txtUser.Text
|
|
If txtPort.Text Then Settings["/Conecction/Port"] = txtPort.Text
|
|
|
|
End
|