2010-03-01 61 views

回答

2

在你的例子假定「web_app」永遠是你的web應用程序的根文件夾,您可以參考文件,如...

string path = Server.MapPath("/files/"); 
0

您可以使用var rootFolder = Server.MapPath("~")來檢索物理路徑。

代字號字符~被替換爲您的Web應用程序的根目錄,例如, c:\installation\path\web_app

相關問題