Gets and sets log file name and path.
Log file name and path.
By default the log file is created in the folder where the calling assembly resides. The folder in which you plan store your log files must exist and your web application must have enough permission for writing and creating files in this folder. Note that if you are creating HttpHandler-based server usually on Windows XP your web application runs under ASPNET account while on Windows 2003 it runs under Network Service account.
If you are requesting your server with a WebDAV client and log file is not created, most likely there is no permissions for creating file or the web requests simply does not reach your application.
public class WebDAVHandler : IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
FileLogger.LogFile = context.Request.PhysicalApplicationPath + "WebDAVlog.txt";
...
}
...
}
FileLogger Class | ITHit.WebDAV.Logger Namespace