DBF?? /?? FoxPro????
??? ODBC????
???
???
??? standard:??
???
? "Driver={Microsoft?? dBASE?? Driver?? (*.dbf)};DriverID=277;Dbq=c:\mydbpath;"????
???
???
???
??? OLE?? DB,?? OleDbConnection?? (.NET)????
???
???
??? standard:??
???
? "Provider=Microsoft.Jet.OLEDB.4.0;Data?? Source=c:\folder;Extended?? Properties=dBASE?? IV;User?? ID=Admin;Password="????
???
???
???
??? Visual?? FoxPro????
??? OLE?? DB,?? OleDbConnection?? (.NET)????
???
???
??? Database?? container?? (.DBC):??
???
? "Provider=vfpoledb.1;Data?? Source=C:\MyDbFolder\MyDbContainer.dbc;Password=MyPassWord;Collating?? Sequence=machine"????
???
???
???
??? Free?? TABLE?? directory:??
???
? "Provider=vfpoledb.1;Data?? Source=C:\MyDataDirectory\;Password=MyPassWord;Collating?? Sequence=general"???
? Read?? more?? (Microsoft?? msdn)?? >>??
??? ODBC????
???
???
??? Database?? container?? (.DBC):??
???
? "Driver={Microsoft?? Visual?? FoxPro?? Driver};SourceType=DBC;SourceDB=c:\myvfpdb.dbc;Exclusive=No;Collate=Machine;"????
???
???
???
??? Free?? TABLE?? directory:??
???
? "Driver={Microsoft?? Visual?? FoxPro?? Driver};SourceType=DBF;SourceDB=c:\myvfpdbfolder;Exclusive=No;Collate=Machine;"????
? "Collate=Machine"?? is?? the?? default?? setting,?? for?? other?? settings?? check?? the?? list?? of?? supported?? collating?? sequences?? >>??
???
? Microsoft?? Visual?? Foxpro?? site:?? http://msdn.microsoft.com/vfoxpro
zys59dim?? conn,strConn??
? set?? conn?? =?? server.createObject("ADODB.connection")??
? conn.connectionString?? =?? "Provider=Microsoft.Jet.OLEDB.4.0;Data?? Source=d:\twotab;Extended?? Properties=dBASE?? IV;User?? ID=Admin;Password="???
? conn.open??
? 我用這段話把Connection對象建立起來了,沒有提示錯誤。??
? 然后我寫了如下的話:??
? dim?? rs,strSQL??
? set?? rs?? =?? server.createObject("ADODB.recordSet")??
? strSQL?? =?? "select?? *?? from?? abcd"??
? rs.open?? strSQL,conn,1,3,1??
? abcd是我的vfp_test.dbc下的一個表,存為abcd.dbf,系統提示如下:??
???
? Microsoft?? JET?? Database?? Engine?? 錯誤?? '80004005'????
? 外部表不是預期的格式。????
? /twoTAB/linkVFP.asp,行?? 10????
? 請問這是怎么回事???
?
zys59大家幫忙啊,分不夠可以在加,我菜,我著急,謝謝了,幫忙頂也給分了
ybfqlyq試下這個連接。??
? set?? adocon=Server.Createobject("adodb.connection")??????
????? adocon.open"Driver={microsoft?? Visual?? Foxpro?? driver};sourcetype=DBC;sourceDB=*.dbc;Exclusive=No;"??????
???
???
? ------------------??
? http://www.ybfq.net/article/show.asp?id=2011
liuxiaoyi666www.connectionstrings.com
zys59<%??
? dim?? conn,strConn??
? set?? conn?? =?? server.createObject("ADODB.connection")??
? conn.connectionString?? =?? "Driver={Microsoft?? Visual?? FoxPro?? Driver};SourceType=DBC;SourceDB="&server.mapPath("database/vfp_test.dbc")&";Exclusive=No;"????
? conn.open??
???
? dim?? rs,strSQL??
? set?? rs?? =?? server.createObject("ADODB.recordSet")??
? strSQL?? =?? "select?? *?? from?? abcd"??
? rs.open?? strSQL,conn,1,3,1??
? %>??
? 我的數據庫結構和上貼相同,語句如上,實現了對VFP數據庫的操作。??
? 在這之前我安裝了VFPODBC5.0和MDAC2.7,不知道是哪個管用了。有類似情況的可以試一下。
zys59abcd是我的vfp_test.dbc下的一個表,存為abcd.dbf
zys59謝謝大家幫助,雖然還沒弄明白到底是什么起了作用,但好歹實現了對VFP的控制,高興!再次對大家表示感謝。
??? ODBC????
???
???
??? standard:??
???
? "Driver={Microsoft?? dBASE?? Driver?? (*.dbf)};DriverID=277;Dbq=c:\mydbpath;"????
???
???
???
??? OLE?? DB,?? OleDbConnection?? (.NET)????
???
???
??? standard:??
???
? "Provider=Microsoft.Jet.OLEDB.4.0;Data?? Source=c:\folder;Extended?? Properties=dBASE?? IV;User?? ID=Admin;Password="????
???
???
???
??? Visual?? FoxPro????
??? OLE?? DB,?? OleDbConnection?? (.NET)????
???
???
??? Database?? container?? (.DBC):??
???
? "Provider=vfpoledb.1;Data?? Source=C:\MyDbFolder\MyDbContainer.dbc;Password=MyPassWord;Collating?? Sequence=machine"????
???
???
???
??? Free?? TABLE?? directory:??
???
? "Provider=vfpoledb.1;Data?? Source=C:\MyDataDirectory\;Password=MyPassWord;Collating?? Sequence=general"???
? Read?? more?? (Microsoft?? msdn)?? >>??
??? ODBC????
???
???
??? Database?? container?? (.DBC):??
???
? "Driver={Microsoft?? Visual?? FoxPro?? Driver};SourceType=DBC;SourceDB=c:\myvfpdb.dbc;Exclusive=No;Collate=Machine;"????
???
???
???
??? Free?? TABLE?? directory:??
???
? "Driver={Microsoft?? Visual?? FoxPro?? Driver};SourceType=DBF;SourceDB=c:\myvfpdbfolder;Exclusive=No;Collate=Machine;"????
? "Collate=Machine"?? is?? the?? default?? setting,?? for?? other?? settings?? check?? the?? list?? of?? supported?? collating?? sequences?? >>??
???
? Microsoft?? Visual?? Foxpro?? site:?? http://msdn.microsoft.com/vfoxpro
zys59dim?? conn,strConn??
? set?? conn?? =?? server.createObject("ADODB.connection")??
? conn.connectionString?? =?? "Provider=Microsoft.Jet.OLEDB.4.0;Data?? Source=d:\twotab;Extended?? Properties=dBASE?? IV;User?? ID=Admin;Password="???
? conn.open??
? 我用這段話把Connection對象建立起來了,沒有提示錯誤。??
? 然后我寫了如下的話:??
? dim?? rs,strSQL??
? set?? rs?? =?? server.createObject("ADODB.recordSet")??
? strSQL?? =?? "select?? *?? from?? abcd"??
? rs.open?? strSQL,conn,1,3,1??
? abcd是我的vfp_test.dbc下的一個表,存為abcd.dbf,系統提示如下:??
???
? Microsoft?? JET?? Database?? Engine?? 錯誤?? '80004005'????
? 外部表不是預期的格式。????
? /twoTAB/linkVFP.asp,行?? 10????
? 請問這是怎么回事???
?
zys59大家幫忙啊,分不夠可以在加,我菜,我著急,謝謝了,幫忙頂也給分了
ybfqlyq試下這個連接。??
? set?? adocon=Server.Createobject("adodb.connection")??????
????? adocon.open"Driver={microsoft?? Visual?? Foxpro?? driver};sourcetype=DBC;sourceDB=*.dbc;Exclusive=No;"??????
???
???
? ------------------??
? http://www.ybfq.net/article/show.asp?id=2011
liuxiaoyi666www.connectionstrings.com
zys59<%??
? dim?? conn,strConn??
? set?? conn?? =?? server.createObject("ADODB.connection")??
? conn.connectionString?? =?? "Driver={Microsoft?? Visual?? FoxPro?? Driver};SourceType=DBC;SourceDB="&server.mapPath("database/vfp_test.dbc")&";Exclusive=No;"????
? conn.open??
???
? dim?? rs,strSQL??
? set?? rs?? =?? server.createObject("ADODB.recordSet")??
? strSQL?? =?? "select?? *?? from?? abcd"??
? rs.open?? strSQL,conn,1,3,1??
? %>??
? 我的數據庫結構和上貼相同,語句如上,實現了對VFP數據庫的操作。??
? 在這之前我安裝了VFPODBC5.0和MDAC2.7,不知道是哪個管用了。有類似情況的可以試一下。
zys59abcd是我的vfp_test.dbc下的一個表,存為abcd.dbf
zys59謝謝大家幫助,雖然還沒弄明白到底是什么起了作用,但好歹實現了對VFP的控制,高興!再次對大家表示感謝。
更多文章、技術交流、商務合作、聯系博主
微信掃碼或搜索:z360901061

微信掃一掃加我為好友
QQ號聯系: 360901061
您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描下面二維碼支持博主2元、5元、10元、20元等您想捐的金額吧,狠狠點擊下面給點支持吧,站長非常感激您!手機微信長按不能支付解決辦法:請將微信支付二維碼保存到相冊,切換到微信,然后點擊微信右上角掃一掃功能,選擇支付二維碼完成支付。
【本文對您有幫助就好】元
