Save As - PDF OPTIONS

Originally Posted 10 November 2016, 8:32 pm EST

  • Originally Posted 10 November 2016, 8:32 pm EST

    V2.0.20163.212

    Hi guys

    just wondering how I can access the Document Restrictions (see attachment) when saving a file as pdf (using the C1PrintPreviewControl). I have seen others specify how to access it via creating a PdfExporter etc, however I believe they do this by having a specific button on the form to export it). I want to access it when they are pressing the save button (and selecting pdf as the type) so I don't need to add a specific button.

    Many thanks
    Connor

  • Reply

    Hi,
    You can access these options via creating a PdfExporter as:
        PdfExporter pdf = new PdfExporter();
    pdf.Security.AllowPrint = true;
    pdf.Security.AllowCopyContent = true;
    pdf.Security.AllowEditContent = true;
    pdf.Security.AllowEditAnnotations = true;


    Hope, it will help you.

    Thanks,
    Sonu
  • Reply

    Hi Sonu,

    thanks for that, however I want to tap into the save as dialog (ie the user previews, then goes save as, then selects the type as PDF, then the pdf options. Its this I want to tap into. I don't want to have to put an additional button to save the pdf if I can.
  • Reply

    Hi,
    Please note, this is not possible directly with the c1PrintPreviewControl. However, you can achieve the same using a ToolStripButton and export the document with SaveFileDialog.
    Please find a sample application attached for complete implementation.

    Hope, it will solve your issue.

    Thanks,
    Sonu
    2016/11/PrintOptionsWithPrintPreviewControl.zip
  • Marked as Answer

    Reply

    Hi Sonu,

    that's what I was trying to avoid (putting a button on the viewer) but if it can't be done it can't be done. Thanks for your help and example of the other way. :)

    Connor
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels