vba连接access出现问题~~帮忙进来看下~~谢谢
Dim hasrecord As BooleanDim i As Integer
isseroprt = False
Adodc1.RecordSource = "select*from 表1;"
With Adodc1.Recordset
.AddNew
' .Fields(0)=
.Fields(1) = wslx
.Fields(2) = TextBox1.Text
.Fields(3) = y(1)
.Fields(4) = y(2)
.Fields(5) = y(3)
.Fields(6) = z(0)
.Fields(7) = y(4)
.Fields(8) = z(1)
.Fields(9) = y(5)
.Fields(10) = z(2)
.Fields(11) = x(1)
.Fields(12) = y(6)
.Fields(13) = y(7)
.Fields(14) = x(2)
.Fields(15) = y(8)
.Fields(16) = y(9)
.Update
isuseroprt = True
MsgBox "您的数据保存成功", vbExclamation + vbOKCancel, "恭喜"
End With
会出现错误91
错误在 .AddNew这行
说对象变量或with语块未设置~~
这是什么原因啊~~
高手请指教 我用了个ADO控件 里面也测试了 能连接上数据库~~但是不知道到怎么存怎么读数据
上面是我写的存数据代码~~~请问哪出了问题啊
随便在请高手指点下 读的代码是什么啊~~~
谢谢~~万分感谢
页:
[1]