1
我試圖從SQLite數據庫中檢索密碼。密碼所在行的ID是1.我想將他的密碼分配給一個名爲actualpass的變量。從SQLite數據庫中進行選擇並將其分配給變量
這是就在我陷入困境之前。誰能幫忙?
Private Sub LoginButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles LoginButton.Click
Dim SQConnect As New SQLite.SQLiteConnection
Dim SQCommand As New SQLite.SQLiteCommand
Dim actualpass As String
Dim givenname As String
Dim path As String
path = AppDomain.CurrentDomain.BaseDirectory()
givenname = txtUsername.Text
SQConnect.ConnectionString = ("Data Source=" & path & "app_data\data.db3")
SQConnect.Open()
SQCommand = SQConnect.CreateCommand
SQCommand.CommandText = ("SELECT password from login_data WHERE id =1")
End Sub
有點調整,這工作:)謝謝! – 2009-12-21 23:59:59
NP(十五個字符填充符) – GrayWizardx 2009-12-22 00:42:30