I have the following entry in my web.config file:
<connectionStrings>
<add name="ConnectionString" connectionString="Server=XXX\SQLEXPRESS;Database=Test;Uid=sa;Pwd=XXXXX"></add>
</connectionStrings>
I am trying to access the connection string as follows:
Dim lcConStr As String
lcConStr = ConfigurationManager.AppSettings("ConnectionString")
txtLocation.Text = lcConStr
When ran, the textbox comes up empty. What could be the problem?
<connectionStrings>
<add name="ConnectionString" connectionString="Server=XXX\SQLEXPRESS;Database=Test;Uid=sa;Pwd=XXXXX"></add>
</connectionStrings>
I am trying to access the connection string as follows:
Dim lcConStr As String
lcConStr = ConfigurationManager.AppSettings("ConnectionString")
txtLocation.Text = lcConStr
When ran, the textbox comes up empty. What could be the problem?