Application Path in ASP.NET

squirrel

Member
Joined
May 12, 2003
Messages
13
Location
UK
I need to read from an XML file located on the localhost in the same folder as my application but when I pass the name "MyXML.xml" the app tries to look for it in C:\Windows\System32.

The file will always be located in the same folder as the application, but the application location may eventually change.

Is there an ASP.NET equivalent of the VB.NET Application.StartupPath property?

Thanks in advance
 
Cheers Mutant.

I have also since discovered that calling Server.MapPath("MyFile.xml") also works.

Im very new to the whole ASP thing so no doubt I shall be troubling you again.
 
Back
Top