用DAO操作EXCELDBASE
Dim db As Database, rs As Recordset 打开DBF文件: Set db = OpenDatabase("d:\tmp", False, False, "dbase 5.0") Set rs = db.OpenRecordset("select * from test", dbOpenDynaset) 打开XLS文件: Set db = OpenDatabase("d:\tmp.xls", False, False, "EXCEL 8.0;HDR=Yes;") Set rs = db.OpenRecordset("select * from [Sheet1$]
用户评论