在做數據庫備份的時候,我在Global.asax的Application_Start事件中啟動定時器,我要得到數據庫所在的目錄路徑還有保存文件的路徑使用的是HttpContext.Current.Server.MapPath,但是,這個httpContext.Current怎么老是個null呀!那么怎樣才能得某個文件的路徑呢?
在Application_Start事件中得不到HttpContext.Current!!
幕布斯6054654
2018-11-20 05:01:00