Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Reading web config files

2 views
Skip to first unread message

sahridhayan

unread,
Mar 30, 2005, 4:15:03 AM3/30/05
to
We have an application develped in asp.net whcih supports multiple database
the database type is stored in web.config file..

But my BL layer componenet only need to know dbtype.. so what are the best
ways
of storing the db type and reading it..

1. web.config.
2. Remoting config
3. or any xml file
4. remoting singleton component property contains dbtype value.. (once read
from xml file .. and having the value for all along???)

any direction would be helpful..

i don't want to read the IO file for knowing the settings for every Remoting
call...

regards
rajaraman

Brock Allen

unread,
Mar 30, 2005, 10:11:35 AM3/30/05
to
Go ahead and put it in web.config. Once read the settings data is cached.
You can even build your own sections in web.config, and using XmlSerializer
it's fairly simple. Here's a sample:

http://staff.develop.com/ballen/samples/ConfigSample.zip

-Brock
DevelopMentor
http://staff.develop.com/ballen

Anubhav Mishra

unread,
Apr 2, 2005, 11:28:19 PM4/2/05
to
Brock is right go for web.config

Thanks
Anubhav

"sahridhayan" <sahri...@discussions.microsoft.com> wrote in message
news:8888E822-FAB6-42D1...@microsoft.com...

pravee...@gmail.com

unread,
Dec 10, 2014, 2:01:35 AM12/10/14
to
What is the best way to comment Web config file?
0 new messages