log file# DotNet - 窗口里的风景
d*t
1 楼
I want to record the transaction in a log file, which will be placed in a
subdirectory, called log, residing the same directory as my web project. Let's
say, my web project is at: "D:\Inetpub\wwwroot\projectA", and the logfile,
named log.txt, resides at "D:\Inetpub\wwwroot\projectA\log". The question is
how to get the virtual directory of a web project, such as projectA? I don't
want to hardcode this for ease of transfer to other machines.
subdirectory, called log, residing the same directory as my web project. Let's
say, my web project is at: "D:\Inetpub\wwwroot\projectA", and the logfile,
named log.txt, resides at "D:\Inetpub\wwwroot\projectA\log". The question is
how to get the virtual directory of a web project, such as projectA? I don't
want to hardcode this for ease of transfer to other machines.