Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
6
Reply
Web.config File And Connection string
Aman Jen
Jul 30 2013 1:33 AM
1.5k
Reply
Hi,
Is it possible to connection string declared in web config file and use in subpages of Master Page once it defined in master page....because I dont want to declare it again and again in sub pages because that again the same thing like declaring connection string locally like below on every subpage of Master Page
Public connStr As String = ConfigurationManager.ConnectionStrings("myConnectionString").ConnectionString
Public cn As New SqlConnection(connStr)
Public cmd As New SqlCommand
...plz help..
I Hope i am clear with my query
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
6
)
Next Recommended Forum
Message Box
browser close event