Creating new Foxpro database (dbc) from scratch

Trips

Well-known member
Joined
Aug 7, 2010
Messages
2,788
I have a connection string coded in C#/OLEDB to talk to a .dbc file that doesnt exist yet. How do I programmatically create a Foxpro dbc (data base container, I think it stands for)? Am using VS2008, C#. I have installed VFPOLEDBSetup.msi
on my PC and realize each user of my application will need to install that.
<span style="font-size:x-small <font size="2

</font>
<span style="font-size:x-small; color:#2b91af <span style="font-size:x-small; color:#2b91af OleDbConnection<span style="font-size:x-small oleDbConnection1 =
<span style="font-size:x-small; color:#0000ff <span style="font-size:x-small; color:#0000ff new<span style="font-size:x-small
<span style="font-size:x-small; color:#2b91af <span style="font-size:x-small; color:#2b91af OleDbConnection<span style="font-size:x-small (<span style="font-size:x-small; color:#a31515 <span style="font-size:x-small; color:#a31515 "Provider=VFPOLEDB.1;"<span style="font-size:x-small
+<span style="font-size:x-small; color:#a31515 <span style="font-size:x-small; color:#a31515 "Data Source=Quick-Sale.DBC;"<span style="font-size:x-small );
<span style="font-size:x-small oleDbConnection1.Open();
<span style="font-size:x-small Obviously, the "open" bombs. What should I do? All the examples I find at MSDN or elsewhere, deal with creating new tables AFTER you already have a .DBC. I dont have Foxpro, but I want to make a C#
application that will create and maintain its data in Foxpro files. Im aware of "free tables", but intuitively I suspect having a .DBC is better. There MUST be a way to create it from scratch.
<span style="font-size:x-small (I thought of posting to VFP forum, but they seems to deal only in the VFP language.)

View the full article
 
Back
Top