ASP::::
用vb里的“外接程序管理器”里“可视化数据管理器”建立的access vesion 7.0 数据库,无论用 dsn ,还是 provider 的连接都写不进(当加入 rs.addnew即出错),但可以读取出来(此时的CursorType和LockType都没设)!如果加了就会报错!是不是有可能那里设定错了,令数据库只读?还是别的原因???
set cnn=server.createobject("adodb.connection")
Set Cnn = Server.CreateObject("ADODB.Connection")
StrCnn = "Provider = Microsoft.Jet.OLEDB.4.0;Data Source =" & server.mappath("test.mdb")
cnn.open strcnn
set rs=server.createobject("adodb.Recordset")
rs.CursorType = adOpenKeyset '错误类型:ADODB.Recordset (0x800A0BB9)
rs.LockType = adLockOptimistic
rs.Open "menber",Cnn,,,adCmdTable
......
初学......求助......感谢你们的帮助!!!!!!
---------------------------------------------------------------
写入权限问题。检查文件夹安全属性、WEB站点读写权限。
---------------------------------------------------------------
adErrInvalidArgument
0x800A0BB9
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
---------------------------------------------------------------
rs.CursorType = 1 'adOpenKeyset
rs.LockType = 3 'adLockOptimistic
注意VBS和VB不同,在VBS中没有这些常量的定义.
---------------------------------------------------------------
你应该用数字,因为asp里没这个常量