Changing databases

  • Thread starter Thread starter Jim
  • Start date Start date
J

Jim

In C# Express 2008 I have a form filled with data-bound textboxes that were
made by dragging a table to the form from MyDataSet. This works very nicely.

I also have an SQL connection named MyComm to an access database with the
identical schema to the data-source that was used to place the textboxes on
the form. My question is how do I change the databases ? I have tried
researching this question in C# help, MSDN and Google but with no success.
Any suggestions are welcomed, especially an article or sample code.
Thanks,
Jim
 
it is generally trivial, if you use a connection, supply the appropriate
string.

If you use automatically generated code, that may be harder to get the
property. With Microsoft Data Set Generator, .xsd, you can change the Table
Adapter Connection.ConnectionString; with LINQ, use the appropriate
database context overloaded constructor rather than the default one.

Vanderghast, Access MVP
 
Back
Top