how to define connection string in app config file for access databse

Posted by Shanky11 under Windows Forms on 11/19/2013 | Points: 10 | Views : 1560 | Status : [Member] | Replies : 1
i have created a application in that i want to add app config file
and define a connection in app config file
C:\Users\Developer01\Desktop\18-11-2013 old\Measurement\bin\Debug\Calliberation.bdb
how can i open this file to get data ???????????


Posted by: vishalneeraj-24503 on: 11/19/2013 [Member] [MVP] Platinum | Points: 25


You can set your connection string in app.config file in appSettings section
<add key="name_of_your_connection_string_name" value="your_conection_string_parameters"/>

alternatively you can also write your connection string in Setting file:-
right-click on your project -> add -> new item -> select Settings file ->
then in the setting file add N
Name = "your connection string name"
Type = string
Scope = "Application"
Value = "your_conection_string_parameters" like data source = ""

hope this helps you.

Shanky11, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response