捕捉到 System.UnauthorizedAccessException
HResult=-2147024891
Message=对路径“E:\工作文档\Shop\Web\Upfiles\Product.xls”的访问被拒绝。
Source=mscorlib
StackTrace:
在 System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
在 System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
在 System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy)
在 System.IO.FileStream..ctor(String path, FileMode mode)
在 System.Web.HttpPostedFile.SaveAs(String filename)
在 System.Web.UI.WebControls.FileUpload.SaveAs(String filename)
在 Import.TransferData(String excelFile, String sheetName, String connectString) 位置 e:\工作文档\Shop\Web\Import.aspx.cs:行号 25
InnerException: