Runtime

  • Thread starter Thread starter Kenny
  • Start date Start date
K

Kenny

Hi,
Is it possible to have the connection string change during runtime? How?
Thanks,
Kenny
 
Sure, although if you change it when the connection is open, you need to
close and reopen the connection. A simple assignment might be what you're
after (ConnectionString = "..."). Perhaps you want to be able to do it from
outside of your cide, in whiuch case you should look into dynamic properties
or simply loading the connectionstring from you .config file.
 
Back
Top