none
Export to PDF - Custom List form RRS feed

  • Question

  • Hello,

    I have a requirement where in a Custom List form, User needs a Button as Export to PDF. 

    Is it possible to Export the data from Custom List from keeping same format using client side?

    Please let me know possible options to do this client side.

    Thanks in Advance.

    Viral.

    Wednesday, March 1, 2017 12:39 AM

All replies

  • Hi Viral,

    We can use jsPDF to convert the HTML code of the custom list form to PDF.

    Download: https://github.com/MrRio/jsPDF

    Example: http://jsfiddle.net/5ud8jkvf/

    Best Regards,

    Dennis


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Wednesday, March 1, 2017 7:08 AM
    Moderator
  • Thanks Dennis for direction. I tried the example and it seems if there is a Person or Group column displayed on your form the pdf file generated is blank. If i remove the person column from my form then it works fine. Its just that there is extra html with person fields so that messes up the pdf generation process.

    Is there a way to resolve it?

    Thanks,

    Viral.

    Wednesday, March 1, 2017 6:22 PM
  • Hi Viral,

    As a workaround, we can generate the normal HTML code instead of the Person or Group column HTML code using jQuery code, then export to PDF.

    Best Regards,

    Dennis


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Thursday, March 2, 2017 2:03 AM
    Moderator
  • Hi Viral,

    You can have a look at below technet wiki. It may help you.

    Generating a PDF Document in SharePoint 2013

    Regards, Jaydeep.

    Thursday, March 2, 2017 5:59 AM