2014-10-24 6 views
0

파일에 액세스하지 않는 보고서를 생성 할 때이 오류 메시지가 나타납니다. IIS 7을 사용하고 있습니다.IIS 7 보고서를 생성 할 때 경로에 대한 액세스가 거부되었습니다.

XXX는 웹 서버와 다른 서버에 있습니다.

2014-10-24 11:04:13,287 [5] ERROR FOUNDATION [(null)] - Access to the path '\\XXX \file2022.pdf' is denied. 
System.UnauthorizedAccessException: Access to the path '\\XXX\file.pdf' is denied. 
    at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) 
    at 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) 
    at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy) 
    at System.IO.FileStream..ctor(String path, FileMode mode) 
    at CrystalDecisions.CrystalReports.Engine.FormatEngine.WriteStreamToFile(Stream stream, String filename) 
    at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportStreamToFile(Stream stream, DiskFileDestinationOptions options) 
    at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext) 
    at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToDisk(ExportFormatType formatType, String fileName) 
    at GlobalFunctions.GenerateCrystalReport(String reportFileName, String outputFileName, List`1 params) in C:\NetProjects\branches\R7\GUIs\Foundation\App_Code\GlobalFunctions.vb:line 347 

답변

0

이와 같은 파일에 액세스해야하는 경우 응용 프로그램 풀이 해당 위치에 대한 읽기 권한이있는 도메인 사용자로 실행되고 있는지 확인하십시오.

+0

ID는 네트워크 서비스이며, 읽기 권한을 부여 할 대상은 무엇입니까? –

+0

대신 사용자 지정 계정을 설정 한 다음 해당 계정에 대한 사용 권한을 부여하십시오. – embee

관련 문제