Error when using RenderViewToStringAsync method



  • I am getting an error when using the IJSReportMVCService.RenderViewToStringAsync() method. My cshtml file is located directly under the Views Folder in my application.
    Here is the stacktrace:

    /Views/Report/Report.cshtml
    /Views/Shared/Report.cshtml
    /Pages/Shared/Report.cshtml
       at Microsoft.AspNetCore.Mvc.ViewEngines.ViewEngineResult.EnsureSuccessful(IEnumerable`1 originalLocations)
       at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewResultExecutor.ExecuteAsync(ActionContext context, ViewResult result)
       at Microsoft.AspNetCore.Mvc.ViewResult.ExecuteResultAsync(ActionContext context)
       at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeResultAsync(IActionResult result)
       at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeNextResultFilterAsync[TFilter,TFilterAsync]()
       at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Rethrow(ResultExecutedContext context)
       at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.ResultNext[TFilter,TFilterAsync](State& next, Scope& scope, Object& state, Boolean& isCompleted)
       at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeResultFilters()
       at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeNextResourceFilter()
       at Microsoft.AspNetCore.Mvc.Internal.MiddlewareFilterBuilder.<>c.<<BuildPipeline>b__8_0>d.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at jsreport.AspNetCore.JsReportMiddleware.Invoke(HttpContext context)```


  • Please share somewhere a sample project replicating the problem so we can take a look.
    Or you can try to debug this.


Log in to reply
 

Looks like your connection to jsreport forum was lost, please wait while we try to reconnect.