Private Sub Command5_Click()
If Text5.Text = "" Or Text6.Text = "" Then
MsgBox "用户名或密码为空!", 48, "警告"
Else
Adodc1.ConnectionString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=图书馆"
Adodc1.RecordSource = "select * from 管理人员登陆 where 帐号='" & Trim(Text5.Text) & "' and 密码='" & Text6.Text & "'"
Adodc1.Refresh
If Adodc1.Recordset.EOF Then
MsgBox "用户名或密码不正确,重新输入!", 48, "警告"
Text5.Text = ""
Text6.Text = ""
Text5.SetFocus
Else
select_into.Show
Unload Me
End If
End If
End Sub
Private Sub Command6_Click()
a = MsgBox("真的要退出吗?", 1 + 32, "提示")
If a = vbOK Then
Unload Me
End If
End Sub
Private Sub Command7_Click()
mes_search.Show
Unload Me
End Sub
Private Sub Command8_Click()
baobiao.Show
End Sub
查询图书信息界面:
代码
Private Sub Command1_Click()
If Text1.Text = "" Or Text2.Text = "" Then
MsgBox "用户名或密码为空!", 48, "警告"
Else
Adodc1.ConnectionString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=图书馆"
Adodc1.RecordSource = "select * from 工作人员登陆 where 帐号='" & Trim(Text1.Text) & "' and 密码='" & Text2.Text & "'"
Adodc1.Refresh
If Adodc1.Recordset.EOF Then
MsgBox "用户名或密码不正确,重新输入!", 48, "警告"
Text1.Text = ""
Text2.Text = ""
Text1.SetFocus
Else
borrow.Show
Unload Me
End If
End If
End Sub
Private Sub Command2_Click()
a = MsgBox("真的要退出吗?", 1 + 32, "提示")
If a = vbOK Then
Unload Me
End If
End Sub
Private Sub Command3_Click()
If Text3.Text = "" Or Text4.Text = "" Then
MsgBox "用户名或密码为空!", 48, "警告"
Else
Adodc1.ConnectionString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=图书馆"
Adodc1.RecordSource = "select 卡号 ,密码 from 借书卡表 where 卡号='" & Trim(Text3.Text) & "' and 密码='" & Text4.Text & "'"
Adodc1.Refresh
If Adodc1.Recordset.EOF Then
MsgBox "用户名或密码不正确,重新输入!", 48, "警告"
Text3.Text = ""
Text4.Text = ""
Text3.SetFocus
Else
card_in.Show
Unload Me
End If
End If
End Sub
Private Sub Command4_Click()
a = MsgBox("真的要退出吗?", 1 + 32, "提示")
If a = vbOK Then
Unload Me
End If
End Sub
Private Sub Command5_Click()
If Text5.Text = "" Or Text6.Text = "" Then
MsgBox "用户名或密码为空!", 48, "警告"
Else
Adodc1.ConnectionString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=图书馆"
Adodc1.RecordSource = "select * from 管理人员登陆 where 帐号='" & Trim(Text5.Text) & "' and 密码='" & Text6.Text & "'"
Adodc1.Refresh
If Adodc1.Recordset.EOF Then
MsgBox "用户名或密码不正确,重新输入!", 48, "警告"
Text5.Text = ""
Text6.Text = ""
Text5.SetFocus
Else
select_into.Show
Unload Me
End If
End If
End Sub
Private Sub Command6_Click()
a = MsgBox("真的要退出吗?", 1 + 32, "提示")
If a = vbOK Then
Unload Me
End If
End Sub
Private Sub Command7_Click()
mes_search.Show
Unload Me
End Sub
Private Sub Command8_Click()
baobiao.Show
End Sub
查询图书信息界面:
上一页 [1] [2] [3] [4] [5] [6] 下一页