运行时出现错误,缺少数组?

xuyaoqiong 2008-05-09 01:35:36
Private Function CheckData() As Boolean
Dim rst As ADODB.Recordset
If (Trim(txtUserId.Text) = "") Then
MsgBox ("用户ID不能为空!")
CheckData = False
Exit Function
ElseIf Len(Trim(txtUserId.Text)) <> 6 Then
MsgBox ("用户ID不是6位!")
CheckData = False
Exit Function
ElseIf Len(Trim(txtName.Text)) <> 6 Then
MsgBox ("密码不能少与6位!")
CheckData = False
Exit Function
ElseIf (Trim(Text3.Text) = "") Then
MsgBox ("个人认证码不能为空!")
CheckData = False
Exit Function
End If
If Not txtName.Text = txtname2.Text Then
MsgBox "两次密码输入不同!"
End If
SQL = " select id from s where id='" & Trim(txtUserId.Text) & "'"
Set rst = SelectSQL(SQL, msg)
If flag = "Add" And rst.RecordCount > 0 Then
MsgBox ("该用户已存在!")
rst.Close
CheckData = False
Exit Function
End If
CheckData = True: MsgBox "注册成功!"
End Function






错误停留在SelectSQL,请问是什么问题呢?
...全文
165 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
舉杯邀明月 2008-05-09
  • 打赏
  • 举报
回复
SelectSQL() 的调用需要的参数是些什么?

把它的声明形式贴出来!
tanjiunnya 2008-05-09
  • 打赏
  • 举报
回复
我不明白:

1)SelectSQL到底是什么功能?请贴出代码

2)msg那里得到的?

7,759

社区成员

发帖
与我相关
我的任务
社区描述
VB 基础类
社区管理员
  • VB基础类社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧