Change the connection string of the associated dataset at runtime

Is it possible to change the connection string of a bound dataset at runtime?

I created an application on my laptop and the server host of my connection is localhost, but when I deploy it to another computer, I wanted my application to be in a database that is on another server.

0


source to share


1 answer


If you choose to keep the connection string in the settings file, this is possible. You will have to override the getter for the connection string. See this page for a full explanation in C #. You should have the same concept and port it to VB.



0


source







All Articles