Questions tagged [webconfigurationmanager]
41 questions
0
votes
2 answers
Find out which web.config(s) have been loaded
I'm encountering an error indicating that the web.config being loaded by this particular sub-project of my solution has a connectionstring that conflicts with an existing entry from an already-loaded web.config
(Exception message is: Additional…

Caius Jard
- 72,509
- 5
- 49
- 80
0
votes
1 answer
Web config encryption using DataProtectionConfigurationProvider is not working on Production
I have used DataProtectionConfigurationProvider to encrypt the connection strings of web config, which is working fine in local.
But when I uploaded the code to production, the web config is not getting encrypted.
I have used following…

Jayakrishnan
- 4,232
- 2
- 23
- 35
0
votes
0 answers
Asp.net web.config for dev/release without transforms
I would like to have distinct and complete web.debug.config and web.release.config files - instead of partials that transform into complete file on build or publish.
How to I associate the configuration with the file?

DFBerry
- 1,818
- 1
- 19
- 37
0
votes
2 answers
how can i use same web.config file for two web appliction?
I have two web application. Their folder hierarchy in server is like that.
first one is : .../firstapplitaion
second is : .../firstapplication/secondapplication/Default.aspx
At first can i run them with just firstapplication's web.config file?…

cagin
- 5,772
- 14
- 74
- 130
0
votes
0 answers
Which of the two, WebConfigurationManager or ConfigurationManager, to use from within a class library?
I have some code in a class library that reads stuff from the client application's configuration file.
Which of the two classes should I use to read the data? Should I use the WebConfigurationManager or the ConfigurationManager if I want my code to…

Water Cooler v2
- 32,724
- 54
- 166
- 336
0
votes
2 answers
WebConfigurationManager error after adding siteMap
I'm getting this error:
Compiler Error Message: CS0118: 'Configuration' is a 'namespace' but is used like a 'type'
Configuration myWebConfig = WebConfigurationManager.OpenWebConfiguration("~/");
This code has been in place for 5+ months without this…

aron
- 2,856
- 11
- 49
- 79
0
votes
1 answer
Using the WebConfigurationManager.OpenWebConfiguration() function using remote server and port?
Can someone tell me if there is a way for me to use the WebConfigurationManager.OpenWebConfiguration() using a remote server, port and virtual directory?
Examples cited in http://msdn.microsoft.com/en-us/library/ms228063.aspx and…

D0cNet
- 314
- 4
- 20
0
votes
1 answer
Exception with WebConfigurationManager.AppSettings.Get("urlAddress")
I am very new to working with XML. I've been weeding my way through debugging a project that was handed to me, but have run into quite a wall.
My code:
XmlWriter xmlWriter = XmlWriter.Create("ToPost.xml");
xmlWriter.WriteStartDocument();
…

Derek N
- 19
- 1
- 6
0
votes
0 answers
What is the alternative for using Activator.CreateInstance() method?
I am creating an object of the logger type dynamically, trying to use the concept of Reflection. My code is as follows.
public static ILogger Create(string loggerType)
{
ILogger logger = null;
string loggerValue =…

Maruthi Revankar
- 331
- 2
- 5
- 17
0
votes
1 answer
Update current web.config on-line
I've created a screen on my web application that will allow super administrators change values of parameters on Web.Config.
The problem
One time we change the values of parameters using that code users connected to the applications have to refreshed…

user1520494
- 1,134
- 2
- 11
- 27
0
votes
1 answer
How to retrieve web.config setting in web application subfolder
I have a subfolder in my web application. It's not a separate application, just a subfolder, but it has its own web.config. There is an aspx page in that subfolder which needs to access a setting in the web.config file in its own folder.
When I…

Triynko
- 18,766
- 21
- 107
- 173