Geeks With Blogs
Eron Wright - All Killer No Filler blog

I have heard Don Box speak about the caviats of using the Indigo service model.  He states that service classes should not use transport-specific API - notably the use of HttpContext.  The logic is obvious. 

The problem is that my ASMX web services must often use XSD files that are in the same directory as the ASMX file. HttpContext.Current.Server.MapPath is used to resolve to a local path.  What is the recommended API for doing such resolution without HttpContext?  Don, your comments would be appreciated.

Posted on Sunday, February 29, 2004 6:00 AM Technology | Back to top


Comments on this post: Indigo - use of HttpContext.Current.Server.MapPath

# re: Indigo - use of HttpContext.Current.Server.MapPath
Requesting Gravatar...
You can use AppDomain.CurrentDomain.BaseDirectory to accomplish the same things in all .NET apps.
Left by Paul Wilson on Feb 29, 2004 6:46 AM

# re: Indigo - use of HttpContext.Current.Server.MapPath
Requesting Gravatar...
Thank you. I have been all over the net looking for the base directory of my app.
Left by Rodney Britt on Sep 10, 2008 8:58 PM

Your comment:
 (will show your gravatar)


Copyright © Eron Wright | Powered by: GeeksWithBlogs.net