TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Sumi D
NA
4
4.3k
when I browse from IIs not add connection string to webconfig file
Nov 26 2011 2:06 AM
System.Configuration.ConnectionStringSettings connection = new
System.Configuration.ConnectionStringSettings("helloConnectionstring5", constr, "System.Data.SqlClient");
var settings = System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration(@"/");
settings.ConnectionStrings.ConnectionStrings.Add(connection);
settings.Save();
Global.StartupType = Global.STARTUP_TYPE.NORMAL;
lblstatus.Text = "Connection success and connectionstring updated in webconfig";
this is my code for adding connectionstring in webconfig file.
But this working in my local system.
after configuring IIS.when I browse from there it wont add connection string to webconfig file.
Reply
Answers (
2
)
Basic Concept in C#
C#. Dictionary(translator) implemention