Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Security Error

Status
Not open for further replies.

kennyaidan

Programmer
Apr 9, 2003
54
IE
Hi,
I am trying to create aspx files and folders on an IIS server and i got the following error

Security Exception
Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.

Exception Details: System.Security.SecurityException: Exception from HRESULT: 0x800A0046 (CTL_E_PERMISSIONDENIED).

The code i used was
outputfile = fso.CreateTextFile("C:\Inetpub\ & storydate & "\" & storyfile & ".aspx", True)

Does anyone know how to change the permissions on an IIS server so that i am able to create files and folders on it. Any help greatly appreciated.
Thanks
Aidan
 

Hi kennyaidan

I am assuming that you have access rights to the IIS Admin Control Panel for this.

1. Open Control Panel (Start, Settings, Control Panel)
2. Open Administrative Tools
3. Open Internet Services Manager
4. In ISM, find the computer with your website running on it, Open It
5. Open Default Website
6. Find the virtual folder where your application is location, right click on it
7. Choose properties and a properties box should pop up
8. Here you can see the local path of your app and set the permissions
Check the 'Write' permissions checkbox, hit apply and then ok

You should be all set.

S.


(The more ASP.NET I do, the more Javascript I find myself using)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top