levanduyet nói:
Chào Hai,
Em có ví dụ nào trong Visual basic, dùng ADO để thao tác với CSDL Visual Foxpro k? Nếu có gởi cho anh tham khảo.
Cám ơn nhiều.
Thân,
Lê Văn Duyệt
ODBC Driver For Visual FoxPro With a database container: oConn.Open "Driver={Microsoft Visual FoxPro Driver};" & _
"SourceType=DBC;" & _
"SourceDB=c:\somepath\mySourceDb.dbc;" & _
"Exclusive=No;"
Without a database container (Free Table Directory): oConn.Open "Driver={Microsoft Visual FoxPro Driver};" & _
"SourceType=DBF;" & _
"SourceDB=c:\somepath\mySourceDbFolder;" & _
"Exclusive=No;"
For more information, see: Visual FoxPro ODBC Driver and Q165492 OLE DB Data Link Connections Data Link File (UDL)
For Absolute Path:
oConn.Open "File Name=c:\somepath\myDatabaseName.udl;"
For Relative Path:
oConn.Open "File Name=myDatabaseName.udl;"
For more information, see: HOWTO: Use Data Link Files With ADO
Note: Windows 2000 no longer contains the "New | Microsoft Data Link"
menu anymore. You can add the Data Link menu back in the menu list
by running the "C:\Program Files\Common Files\System\Ole DB\newudl.reg"
reg file, Then right-click on the desktop and Select "New | Microsoft Data
Link " menu."
Or you can also create a Data Link file by creating a text file and change
It 's file extension To ".udl", Then double-click the file.
OLE DB Provider For Visual FoxPro oConn.Open "Provider=vfpoledb;" & _
"Data Source=.\MyDB.dbc;"
For more information, see: Microsoft OLE DB Provider for Visual FoxPro