Convert html to PDF Unable to load DLL 'wkhtmltox.dll': The specified module could not be found.

adil 1,206 Reputation points
2021-10-28T08:19:30.117+00:00

Hi,
I moved my Custom Solutions to new SharePoint 2016 Server after upgrade to SharePoint 2013 to 2016, when user browser custom page & click one option Export Data to Pdf , they get below error.

Unable to load DLL 'wkhtmltox.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E) at PFE.Internet.ControlTemplates.Request.ExportTopdf_Click(Object sender, EventArgs e) at System.Web.UI.WebControls.Button.OnClick(EventArgs e) at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

In Old Server SP 2013 previously deployed TuesPechkin.Wkhtmltox thirdparty Tools to export data to PDF.
Here In new Server how can i & where to deploy these DLLS.

SharePoint Server Development
SharePoint Server Development
SharePoint Server: A family of Microsoft on-premises document management and storage systems.Development: The process of researching, productizing, and refining new or existing technologies.
1,567 questions
SharePoint Server Management
SharePoint Server Management
SharePoint Server: A family of Microsoft on-premises document management and storage systems.Management: The act or process of organizing, handling, directing or controlling something.
2,791 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Elsie Lu_MSFT 9,756 Reputation points
    2021-10-29T07:20:35.943+00:00

    Hi @adil ,

    As this post mentioned, you could rebuild the solution.

    1- Open the custom SharePoint Project in your VS.

    2- remove old references (.SharePoint.dll) (.sharepoint..dll) and add new references (.SharePoint.dll) (.sharepoint..dll).

    3- rebuild the solution .

    4- add , deploy, and install the sp solution on the new env.

    Another similar post for your reference:
    Migrating Custom Solutions from SharePoint 2013 to 2019

    And when it comes to third-party products, I would suggest you seek help from third-party suppliers.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


  2. sadomovalex 3,626 Reputation points
    2021-11-01T15:38:37.337+00:00

    if there is one dll you may just install it to GAC on SP2019 WFE server:

    gacutil -i wkhtmltox.dll