Click here to Skip to main content
16,008,490 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionFinding control Pin
TAK7819-Apr-07 7:08
TAK7819-Apr-07 7:08 
AnswerRe: Finding control Pin
Sujit Gupta19-Apr-07 7:29
Sujit Gupta19-Apr-07 7:29 
GeneralRe: Finding control Pin
TAK7819-Apr-07 7:32
TAK7819-Apr-07 7:32 
GeneralRe: Finding control Pin
TAK7819-Apr-07 8:05
TAK7819-Apr-07 8:05 
Questionbackground images are not showing up???? Pin
cpltek19-Apr-07 7:04
cpltek19-Apr-07 7:04 
QuestionImages on ASP.Net Web Developer 2005 Pin
Mshapis19-Apr-07 6:02
Mshapis19-Apr-07 6:02 
AnswerRe: Images on ASP.Net Web Developer 2005 Pin
kubben19-Apr-07 6:21
kubben19-Apr-07 6:21 
QuestionAccess denied when saving the web.config file Pin
steve_rm19-Apr-07 5:55
steve_rm19-Apr-07 5:55 
Hello

VS 2005

I am using the code below to get and save the connection string in the web.config file. However on the webConfig.Save() line it throws an error:

An error occurred loading a configuration file: Access to the path 'c:\inetpub\wwwroot\Incidents_WS\oa48wsfg.tmp' is denied. (c:\inetpub\wwwroot\Incidents_WS\web.config)

I am not sure what this file is "oa48wsfg.tmp" and why I have access denied.

<br />
 Dim cnnString As String<br />
'Get the current connection string<br />
        cnnString = WebConfigurationManager.ConnectionStrings("serviceMasterConnectionString").ConnectionString()<br />
        cnn.ConnectionString = cnnString<br />
<br />
'Save a new connection string<br />
        Dim WebConfig As Configuration<br />
        WebConfig = WebConfigurationManager.OpenWebConfiguration("~")<br />
        WebConfig.ConnectionStrings.ConnectionStrings("serviceMasterConnectionString").ConnectionString = "data source=steve01\ssd01; database=serviceMaster; user id=sa; pwd=a123"<br />
        WebConfig.Save()'Error on this line.<br />


I have gone into the IIS and right click web.config and given read and write permissions. but still get the same error message.

Can anyone please help me with this problem.

Many thanks,

Steve
AnswerRe: Access denied when saving the web.config file Pin
Cfer8319-Apr-07 6:03
Cfer8319-Apr-07 6:03 
AnswerRe: Access denied when saving the web.config file Pin
kubben19-Apr-07 6:23
kubben19-Apr-07 6:23 
Questionoracle query Pin
Hasan Ali19-Apr-07 5:33
Hasan Ali19-Apr-07 5:33 
AnswerRe: oracle query Pin
Hasan Ali19-Apr-07 5:37
Hasan Ali19-Apr-07 5:37 
GeneralRe: oracle query Pin
rama charan19-Apr-07 5:48
rama charan19-Apr-07 5:48 
GeneralRe: oracle query Pin
Hasan Ali19-Apr-07 7:26
Hasan Ali19-Apr-07 7:26 
GeneralRe: oracle query Pin
Hasan Ali19-Apr-07 8:52
Hasan Ali19-Apr-07 8:52 
GeneralRe: oracle query Pin
Hasan Ali19-Apr-07 8:54
Hasan Ali19-Apr-07 8:54 
GeneralRe: oracle query Pin
Hasan Ali19-Apr-07 9:09
Hasan Ali19-Apr-07 9:09 
Questionchat window Pin
saravanan0519-Apr-07 4:25
saravanan0519-Apr-07 4:25 
AnswerRe: chat window Pin
steffw19-Apr-07 4:31
steffw19-Apr-07 4:31 
QuestionRestrict User to visit any middle page Pin
meeram39519-Apr-07 4:18
meeram39519-Apr-07 4:18 
AnswerRe: Restrict User to visit any middle page Pin
Tarakeshwar Reddy19-Apr-07 4:40
professionalTarakeshwar Reddy19-Apr-07 4:40 
QuestionPass string to error page Pin
mail57235219-Apr-07 3:45
mail57235219-Apr-07 3:45 
AnswerRe: Pass string to error page Pin
Tarakeshwar Reddy19-Apr-07 3:55
professionalTarakeshwar Reddy19-Apr-07 3:55 
GeneralRe: Pass string to error page Pin
mail57235219-Apr-07 13:37
mail57235219-Apr-07 13:37 
QuestionHyperlinks in datagrid! Pin
nclauder19-Apr-07 3:27
nclauder19-Apr-07 3:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.