to water_j: 可以的Intrinsic Data Control Is Usable with Access 2000 Databases See AlsoAt design time, trying to bind the Data control to a Microsoft Access 2000 database will result in an error: "Unrecognized database format." The Data control can still be used, however, by following the example below: On the Project menu, click References. Clear the Microsoft DAO 3.51 Object Library check box. Set a reference to the Microsoft DAO 3.6 Object Library. Draw a Data control and a TextBox control on a form. On the Properties window, set the TextBox control's DataSource property to the Data control. Type the name of the field CompanyName into the DataField property box. Insert code similar to the following into the code window: Option Explicit Private daoDB36 As Database Private rs As Recordset Dim sPath As StringPrivate Sub Form_Load() sPath = _ "C:\Program Files\Microsoft Office\Office\Samples\Northwind.mdb" Set daoDB36 = DBEngine.OpenDatabase(sPath) Set rs = daoDB36.OpenRecordset("Customers") Set Data1.Recordset = rs End SubRun the project. 当然,您安装了SP5,就没有必要执行以上动作了
1. 新建一个工程
2. 添加一个Data Control在任何一个窗体
3. 工程->引用
4. 看您的VB引用了什么版本的DAO
可以的Intrinsic Data Control Is Usable with Access 2000 Databases
See AlsoAt design time, trying to bind the Data control to a Microsoft Access 2000 database will result in an error: "Unrecognized database format." The Data control can still be used, however, by following the example below: On the Project menu, click References. Clear the Microsoft DAO 3.51 Object Library check box.
Set a reference to the Microsoft DAO 3.6 Object Library.
Draw a Data control and a TextBox control on a form.
On the Properties window, set the TextBox control's DataSource property to the Data control.
Type the name of the field CompanyName into the DataField property box.
Insert code similar to the following into the code window:
Option Explicit
Private daoDB36 As Database
Private rs As Recordset
Dim sPath As StringPrivate Sub Form_Load()
sPath = _
"C:\Program Files\Microsoft Office\Office\Samples\Northwind.mdb"
Set daoDB36 = DBEngine.OpenDatabase(sPath)
Set rs = daoDB36.OpenRecordset("Customers")
Set Data1.Recordset = rs
End SubRun the project.
当然,您安装了SP5,就没有必要执行以上动作了
vb6(CN) sp5
access 2000
我就是这么解决的。
不过数据引擎jet.4.0
对了怎么给分 呀,现在给分好象和以前不一样了