2

How can i configure IIS Express to run my asp.net application from a specific dir location ?

I've copied my app to c:\www\apptest and I have a batch file to start the iis express and then open the localhost url:

iisexpress.exe /path:c:\www\ /port:8888

but in IIS Express it doesn't appear my app name like a site, just localhost:8888. And when entering in localhost:8888/apptest i have an error:

Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

How can i configure my Site in IIS Express ? I think it's Virtual Directory. Where i can configure it ?

Proposition Joe
  • 107
  • 2
  • 13
  • I've found out the answer. Need to edit the applicationhost.config file and set the path. You can close now. – Proposition Joe Aug 30 '12 at 16:24
  • Why not add it as an answer? It's bound to be helpful to other people if it's a good answer. Please make it a substantial answer though. – casperOne Aug 30 '12 at 16:31
  • see http://stackoverflow.com/questions/4731608/iis-7-5-express-new-virtual-dir – Laramie Nov 09 '12 at 23:15
  • Microsoft needs an IIS Manager interface for IIS Express, so this is not an issue. There is often no way to configure an IIS Express application for testing through Visual Studio, so one must manually edit the application.config file in "Users\[username]\Documents\IIS Express". For example, my application had to be debugged with a directory structure similar to the main IIS site, and to do so, I had to add a child application to the application.config file, in addition to the root application. – Triynko Nov 06 '13 at 19:50

0 Answers0