Hi
I want to know how the connectionstring is retrieved from this code
Application[Constants.appSettingsDataFolderPath] = ConfigurationManager.AppSettings[Constants.appSettingsDataFolderPath]
Thanks
Akila
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Pradeep ChandrakerPosted Jun 22, 2011, 10:28 AM
string connStr = ConfigurationManager.AppSettings[Constants.appSettingsDataFolderPath].ToString();
Or, you can try this if you have your database connection information in web.config connectionStrings section.
string connStr = ConfigurationManager.ConnectionStrings[Constants.appSettingsDataFolderPath].ConnectionString;
VulpesPosted Jun 22, 2011, 7:41 AM