Resolving relative paths to absolute paths isn’t that hard when you’re working with normal system paths. You can simply use
However when working with ASP.NET, this can be a little trickier. Because the current folder depends on the code that is calling your code, which switches around a bit in ASP.NET.
The best way to do so is by using the Server.MapPath method:
Piece of cake.