在我的 asp.net Web 应用程序中,我必须读取 App_Data 文件夹中的 somef 文件,但我不知道如何设置路径。
如果在网络表单中,我知道我可以使用:
Sever.mapPath("~/App_Data");
但现在我想在 App_code 中检索 .cs 文件中的路径。
所以那里没有 HttpServer 上下文。
任何的想法?
在我的 asp.net Web 应用程序中,我必须读取 App_Data 文件夹中的 somef 文件,但我不知道如何设置路径。
如果在网络表单中,我知道我可以使用:
Sever.mapPath("~/App_Data");
但现在我想在 App_code 中检索 .cs 文件中的路径。
所以那里没有 HttpServer 上下文。
任何的想法?