Web Application Path

  • Thread starter Thread starter Ryan Knopp
  • Start date Start date
R

Ryan Knopp

Simple Question I hope,

Where would I find a static method or Class that will tell me what my file
path is on my current web application. I want the c:\inetpub\wwwroot\blah
Not sure where to start. I looked under System. but couldn't seem to find
anything.

Thanks
Ryan Knopp
 
It's not a static method but Page.MapPath does exactly this.

e.g. in Page_Load event handler:
string s = this.MapPath(".");

Richard
 
Back
Top