Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Custom Control and ConfigurationManager

Status
Not open for further replies.

JontyMC

Programmer
Nov 26, 2001
1,276
GB
I want to create a custom control that queries the database specified by the connectionstring in the ConfigurationManager of the project that will use the custom control. How can I get a handle on the ConfigurationManager from the custom control?

Jon

"I don't regret this, but I both rue and lament it.
 
You could probably create a Property with a ConfigurationManager type and get the page that includes the user control to set the property. I haven't tried it, but it seems logical...


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Good idea. In the end I decided to set a property to be ConnectionString and set that from the page. Thanks for suggestion though.

Jon

"I don't regret this, but I both rue and lament it.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top