Click here to Skip to main content
12,547,806 members (37,076 online)
Rate this:
Please Sign up or sign in to vote.
See more: C#3.5
Hi !
I am new to C#. I have been using Visual Studio 2008.
I have created Windows Forms application. In that, I want to store connection string in Settings.settings or any other file so that it is easy to change.
If you know it please help me.
Thanks in Advance.
Posted 2-Apr-12 6:54am
Updated 2-Apr-12 7:07am

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Connection strings are normally placed in the app.config file under the...wait for it...connectionStrings element.
Aniket S Kulkarni 2-Apr-12 13:19pm
Thanks Mark Nischalke for posting the answer and for your valuable time.
I gone through following steps:
1.Project Properties.
2.Looked for Settings tab.
3.Chosen the type Connection String.
4.Given the value.
That's it.
Thanks again Mark Nischalke.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.161021.1 | Last Updated 2 Apr 2012
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100