rst.Open strsql, db, adOpenKeyset, adLockOptimistic
PrivateSubForm_Load()strsql="SELECT*FROMbtemptableA"ConenctToDatabaserst.Openstrsql,d...
Private Sub Form_Load()
strsql = "SELECT * FROM btemptableA"
ConenctToDatabase
rst.Open strsql, db, adOpenKeyset, adLockOptimistic
If rst.RecordCount() = 0 Then
'clearfield
hidebutton
Else
showbutton
rst.MoveFirst
filltext
End If
End Sub
运行后出现连接到数据库出错!这是什么原因啊!
ConenctToDatabase 连接到数据库! 展开
strsql = "SELECT * FROM btemptableA"
ConenctToDatabase
rst.Open strsql, db, adOpenKeyset, adLockOptimistic
If rst.RecordCount() = 0 Then
'clearfield
hidebutton
Else
showbutton
rst.MoveFirst
filltext
End If
End Sub
运行后出现连接到数据库出错!这是什么原因啊!
ConenctToDatabase 连接到数据库! 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询