Didn't we go through this a couple of months ago?? I get the distinct feeling of deja vu????
Link the DBF into an Access database and then you can treat the dbf just like an Access table.
To achieve the linking, click on "New" on the "Table" tab and select "Link Table" from the list. Change the "Files Of Type" drop down list to "Microsoft FoxPro" and navigate to your dbf. Follow the instructions.
Alternatively, you could possibly try to create an ODBC source to the DBF - don't know if this is possible and have not tried - and use this source in VB to connect to the DBF.
Thanks Simon, and yes we did go through how to link the dbf file to a table in Access. However we did not go through updating the actual dbf file. I tried updating the records from within Access but I could not and I do not think that updating the recordset through VB is allowed. The only way to actually update would have to be through creating an ODBC source to the dbf file as you suggested. My question was, "How can this be done?". Is this done exactly as it is done with Access? I'll attemp to do this and get back to you.
I spent about 6.5 hours trying to get a connection to the dbf file that would allow me to update the records. I finally discovered that eventhough I cannot update the records from within Access, I can with code in VB. I guess this is precisely what you were saying. I assumed that since I was unable to update the records by manually opening the link in Access, using code would produce the same results. Well, my wrong.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.