Rotativa.Mini is an extracted minified version of Rotativa library. It helps you to build pdf file out of HTML string in any .NET platform and makes implementation simpler.

Install-Package Rotativa.Mini

How to use?

  1. Take the output dll file (Rotativa.Mini.dll) and add referance in your project.
  2. Add Wkhtmltopdf.exe File into your project (you can see inside demo project)
           var rotativaPath = @"C:\Users\siraj\source\repos\Rotativa.Mini\Rotativa.Mini.Demo\Rotativa";
            var style = @"C:\Users\siraj\source\repos\Rotativa.Mini\Rotativa.Mini.Demo\Stylesheet1.css";

            var fileHtml = File.ReadAllText(@"C:\Users\siraj\source\repos\Rotativa.Mini\Rotativa.Mini.Demo\dddd.html");

            var options =
              new RotativaMiniOptions()
               .SetPageMargins(1, 1, 5, 1);

            var pdfData = RotativaMiniConverter.ConvertHtml(rotativaPath, options, fileHtml);

            File.WriteAllBytes("Test.pdf", pdfData);

You can little work around to support all the path as relative path