Hello

Does anyone have an example to store the connection string to a file, which
can be edited so that the application can run on clients environement.

hardcoding the connection string doesn't seem to be a good idea.

Thanks

HS

Re: Connection String by Miha

Miha
Thu Feb 17 16:51:41 CST 2005

app.config?
See the
<appSettings> Element
.net help topic.
Take note that you might want to encrypt the file if you are storing a
password there.
Event better is to store the (encrypted) value in registry
Here is an article which you might find useful:
http://msdn.microsoft.com/msdnmag/issues/03/11/ProtectYourData/default.aspx

--
Miha Markic [MVP C#] - RightHand .NET consulting & development
www.rthand.com
SLODUG - Slovene Developer Users Group www.codezone-si.info

"Hemang Shah" <hemang@hemang.net> wrote in message
news:bvednekuS5aHg4jfRVn-pw@rogers.com...
> Hello
>
> Does anyone have an example to store the connection string to a file,
> which can be edited so that the application can run on clients
> environement.
>
> hardcoding the connection string doesn't seem to be a good idea.
>
> Thanks
>
> HS
>



Re: Connection String by Hemang

Hemang
Thu Feb 17 17:09:03 CST 2005

Excellent!

Thanks Miha
"Miha Markic [MVP C#]" <miha at rthand com> wrote in message
news:eKCOBNUFFHA.2572@tk2msftngp13.phx.gbl...
> app.config?
> See the
> <appSettings> Element
> .net help topic.
> Take note that you might want to encrypt the file if you are storing a
> password there.
> Event better is to store the (encrypted) value in registry
> Here is an article which you might find useful:
> http://msdn.microsoft.com/msdnmag/issues/03/11/ProtectYourData/default.aspx
>
> --
> Miha Markic [MVP C#] - RightHand .NET consulting & development
> www.rthand.com
> SLODUG - Slovene Developer Users Group www.codezone-si.info
>
> "Hemang Shah" <hemang@hemang.net> wrote in message
> news:bvednekuS5aHg4jfRVn-pw@rogers.com...
>> Hello
>>
>> Does anyone have an example to store the connection string to a file,
>> which can be edited so that the application can run on clients
>> environement.
>>
>> hardcoding the connection string doesn't seem to be a good idea.
>>
>> Thanks
>>
>> HS
>>
>
>



Re: Connection String by Sahil

Sahil
Sat Feb 19 02:29:54 CST 2005

One more interesting info - in .NET 2.0 you can encrypt portions of your
config file - isn't that awesome? :)
(And this doesn't require any code modification).

- Sahil Malik
http://codebetter.com/blogs/sahil.malik/


"Hemang Shah" <hemang@hemang.net> wrote in message
news:4Y6dnQhsYY-SuYjfRVn-hQ@rogers.com...
> Excellent!
>
> Thanks Miha
> "Miha Markic [MVP C#]" <miha at rthand com> wrote in message
> news:eKCOBNUFFHA.2572@tk2msftngp13.phx.gbl...
>> app.config?
>> See the
>> <appSettings> Element
>> .net help topic.
>> Take note that you might want to encrypt the file if you are storing a
>> password there.
>> Event better is to store the (encrypted) value in registry
>> Here is an article which you might find useful:
>> http://msdn.microsoft.com/msdnmag/issues/03/11/ProtectYourData/default.aspx
>>
>> --
>> Miha Markic [MVP C#] - RightHand .NET consulting & development
>> www.rthand.com
>> SLODUG - Slovene Developer Users Group www.codezone-si.info
>>
>> "Hemang Shah" <hemang@hemang.net> wrote in message
>> news:bvednekuS5aHg4jfRVn-pw@rogers.com...
>>> Hello
>>>
>>> Does anyone have an example to store the connection string to a file,
>>> which can be edited so that the application can run on clients
>>> environement.
>>>
>>> hardcoding the connection string doesn't seem to be a good idea.
>>>
>>> Thanks
>>>
>>> HS
>>>
>>
>>
>
>