我用vb调用access2000的报表,代码如下:
Const strConPathToSamples = "e:\wkqd_vb\accwlqd.mdb" strdb = strConPathToSamples & "accwlqd.mdb"
' 创建 Microsoft Access 的实例。
Set appAccess = _
CreateObject("Access.Application.9")
**** appAccess.OpenCurrentDatabase strConPathToSamples
appAccess.DoCmd.OpenReport "gysrzxx_dytj", acViewPreview
appAccess.CloseCurrentDatabase
Set appAccess = Nothing到有"****"时,提示"microsoft access不能打开这个数据库,因为他以丢失或已被其他用户按独占方式打开"我改了access的属性以共享方式打开,仍然不行.
Const strConPathToSamples = "e:\wkqd_vb\accwlqd.mdb" strdb = strConPathToSamples & "accwlqd.mdb"
' 创建 Microsoft Access 的实例。
Set appAccess = _
CreateObject("Access.Application.9")
**** appAccess.OpenCurrentDatabase strConPathToSamples
appAccess.DoCmd.OpenReport "gysrzxx_dytj", acViewPreview
appAccess.CloseCurrentDatabase
Set appAccess = Nothing到有"****"时,提示"microsoft access不能打开这个数据库,因为他以丢失或已被其他用户按独占方式打开"我改了access的属性以共享方式打开,仍然不行.
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货