Bug Report T1173136
Visible to All Users

DxDocumentViewer - "Could not find a part of the path" is thrown on export with FileExportedDocumentStorage

created 2 years ago (modified 2 years ago)

Steps to reproduce:

  1. Register all storages:
C#
viewerConfigurator.UseFileDocumentStorage(Path.Combine("Cache", "Document")); viewerConfigurator.UseFileReportStorage(Path.Combine("Cache", "Report")); viewerConfigurator.UseFileExportedDocumentStorage(Path.Combine("Cache", "Exported"));
  1. Export the report from the viewer (no actual Web Farm needed).

Current results:

Code
DevExpress.AspNetCore.Reporting.Logger: Error: DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.WebDocumentViewerRequestControllerAsync.StartExport (startExport) System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\DxBlazorReportCache\DxBlazorReportCache\Cache\Exported\Cache\Exported\25adc5dedc6992df96d8f333d88af66a\ExportResultDetails.json'. at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options) at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize) at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.FileStorageCommonLogic.SaveToFile[T](T obj, String fileName, String subFolderName) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.FileExportedDocumentStorage.AddOrUpdate(String id, ExportedDocumentInfo exportedDocument) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.ExportPollingOperationService.WriteProgress(String operationId, Int32 progress) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.ExportPollingOperationService.StartOperationAsync(String operationId, PrintingSystemBase printingSystem, Func`2 doSynchronousOperation) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.CachedDocumentSourceManagementServiceAsyncBase`1.<>c__DisplayClass56_0.<<StartExportAsync>b__0>d.MoveNext() --- End of stack trace from previous location --- at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.CachedDocumentSourceManagementServiceAsyncBase`1.DoWithDocumentAsync[T](String id, Nullable`1 loadPageIndex, Func`2 funcAsync, Func`1 remoteDocumentFuncAsync) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.CachedDocumentSourceManagementServiceAsyncBase`1.StartExportAsync(String id, String format, ExportOptions options, Object[] editingFieldValues, Boolean inlineResult) at DevExpress.XtraReports.Web.WebDocumentViewer.Native.Services.WebDocumentViewerRequestControllerAsync.StartExport(DocumentExportRequest exportRequest) at DevExpress.XtraReports.Web.Native.ClientControls.RequestManagerResponseWrapper.WrapJsonResult[T](Task`1 response) at DevExpress.XtraReports.Web.Native.ClientControls.Services.RequestManagerBaseAsync`2.WrapWithTryCatchActionAsync(String controllerTypeName, String methodName, String webActionName, ControllerFuncAsync invoker, TController controller, String json
Comments (3)

    Any update on this, please?

    Yaroslav (DevExpress Support) 2 years ago

      @Shamsuddin,

      Our team is finalizing a possible solution. I anticipate a fix will be ready soon. Please monitor this ticket for further updates.

      Yaroslav (DevExpress Support) 2 years ago

        @Shamsuddin,

        Just to add here: if this issue is urgent, consider building an absolute path by combining IHostingEnvironment.ContentRootPath with your folder's name (this alternative should work well).

        Answers approved by DevExpress Support

        created 2 years ago

        We have addressed the issue described in this ticket and will include a fix in our next maintenance update. Should you need to apply our fix prior to official release, you can request a hotfix here.

        Important Notes:

        • Hotfixes may be unavailable for Early Access/Beta builds or updates set for release within a week.
        • .NET only: in the NuGet Package Manager, use your personal NuGet feed and check the "Include prerelease" option to view the hotfix package in the "Updates" tab.

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.