Use sections in the config file and access them…


for the following XML fragment in the config file:-
<add key="DevConnectionstring" value="server=myserver1;database=mydatabase;uid=ashish;pwd=password"/>
<add key="QAConnectionstring" value="server=myserver2;database=mydatabase;uid=ashish;pwd=password"/>
<add key="ProdConnectionstring" value="server=myserver3;database=mydatabase;uid=ashish;pwd=password"/>
  1. Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Random Thoughts

The World as I see it

Simple Programmer

Making The Complex Simple

Ionic Solutions

Random thoughts on software construction, design patterns and optimization.

Long (Way) Off

A tragic's view from the cricket hinterlands

%d bloggers like this: