有关exesql一段代码不理解!请解释下!
有一小段程序不明白,小弟刚学VB没多久~~请高手帮忙!
private sub command1_chilk()
Dim mrc As Adodc1.Recordset
Dim txtsql As String
txtsql = "select * from oper where 用户名='" & Trim$(Text1(0).Text) & "'" & "and 口令='" & Trim$(Text(1).Text) + "'"
Set mrc = exesql(txtsql)
if mrc.recordcount=0 then
n=n+1
if n<3 then
msgbox"没有这个用户,继续登陆",vbokonly+vbexclamation,"信息提示"
.....(以下省略)
主要是这几句不大了解:
txtsql = "select * from oper where 用户名='" & Trim$(Text1(0).Text) & "'" & "and 口令='" & Trim$(Text(1).Text) + "'"
Set mrc = exesql(txtsql)
if mrc.recordcount=0 then
请高手帮忙解释下,谢谢喔~~
尤其这个set mrc=exesql(txtsql)是什么意思?exesql怎么用?什么意思?谢谢喔~
这段代码好象是连接sql,怎么修改连接到 access?我是菜鸟!