0

I am getting following exception on staging server:

   [Exception]
   Rotativa.WkhtmltopdfDriver.Convert(String wkhtmltopdfPath, String switches, String html) +975
   Rotativa.WkhtmltopdfDriver.ConvertHtml(String wkhtmltopdfPath, String switches, String html) +51
   Rotativa.ViewAsPdf.CallTheDriver(ControllerContext context) +1310
   Rotativa.AsPdfResultBase.BuildPdf(ControllerContext context) +250
   Rotativa.AsPdfResultBase.ExecuteResult(ControllerContext context) +66
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResult(ControllerContext controllerContext, ActionResult actionResult) +13
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +56
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +422
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList`1 filters, ActionResult actionResult) +52
   System.Web.Mvc.Async.<>c__DisplayClass28.<BeginInvokeAction>
    b__19() +173
    System.Web.Mvc.Async.<>c__DisplayClass1e.<BeginInvokeAction>
    b__1b(IAsyncResult asyncResult) +100
    System.Web.Mvc.Async.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult) +10
    System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49
    System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeAction(IAsyncResult asyncResult) +27
    System.Web.Mvc.Controller.<BeginExecuteCore>
        b__1d(IAsyncResult asyncResult, ExecuteCoreState innerState) +13
        System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +36
        System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +54
        System.Web.Mvc.Controller.EndExecuteCore(IAsyncResult asyncResult) +41
        System.Web.Mvc.Controller.<BeginExecute>
            b__15(IAsyncResult asyncResult, Controller controller) +12
            System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +28
            System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +54
            System.Web.Mvc.Controller.EndExecute(IAsyncResult asyncResult) +31
            System.Web.Mvc.Controller.System.Web.Mvc.Async.IAsyncController.EndExecute(IAsyncResult asyncResult) +10
            System.Web.Mvc.MvcHandler.<BeginProcessRequest>
                b__4(IAsyncResult asyncResult, ProcessRequestState innerState) +21
                System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +36
                System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +54
                System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) +31
                System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) +9
                System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +9651188
                System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +155

following code is working fine on my local machine:

return new Rotativa.ViewAsPdf("Order", all) { FileName = "Sample.pdf" };

I tried the steps mentioned in Rotativa PDF generation working locally but not on IIS 7, but didn't help.

Thanks

user1400290
  • 1,682
  • 5
  • 23
  • 43
  • You can find the answer here: https://stackoverflow.com/questions/31112349/rotativa-pdf-generation-working-locally-but-not-on-iis-7 – Alexandre N. Feb 02 '18 at 19:07
  • Possible duplicate of [Rotativa PDF generation working locally but not on IIS 7](https://stackoverflow.com/questions/31112349/rotativa-pdf-generation-working-locally-but-not-on-iis-7) – Alexandre N. Feb 02 '18 at 19:10
  • 1
    Did you find any solution to this problem? I am experiencing a similar issue, and the linked question does not help... – Syl20 Jul 24 '18 at 13:08

0 Answers0