How to create password protected pdf thru AX

This question is not answered

Hi All,

I run a report and save it into a .pdf format. These procedures are absolutely fine. But now I need to create a password protected of that .pdf file. Please provide me the procedure how to create password of the pdf while it saves at the time of report run? Kindly help me in giving a solution to this procedure.

With Regards

Rajdip Das - Kolkata

http://dax-world.blogspot.com

All Replies
  • Hi Rajdip, i am thinking about how you can achieve this.. and i am of the opinion that you should not build this as integration/enhancement in ax.. this is why i say this: i believe that ax creates pdf files using free dlls available from Adobe.. however i dont think that abobe have actually made Encryption a part of the free object. so to encrypt a pdf file, you would have to purchase adobe acrobat (writer).. now if you are doing all that, why can the user simply encrypt the file using Abobe acrobat? so generate it of ax, and then encrypt in a acrobat.. it might just save you some time and the client some money.. but i understand that if this is something that is done very often then you might want to streamline the process further.. let us know and we can take it from there. regards, Mohammed
    www.dynamic-ax.co.uk
  •  Hi Mohammed,

    Thanks for your response. Actually now I am stating my requirements..

    I have to generate payslip as report and save into a pdf. After creating pdf then it would be sent to the employee via e-mail. Up to this procedure is absolutely fine. Now I have to incorporate a password protection of each payslip pdf files. Only user will know the password and then they only can the open file by entering selected password. I can't incorporate password in the file.

    Right now I have Acrobat Prof 9.0 and also I have tried with wrapper class in AX of Adobe, there I found the class methods those are returning boolean value. I need such as class/methods/procedure which will make incorporate password into a existing pdf file.


    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com

  • A product called Create!form for Microsoft Dynamics AX by Bottomline Technologies can stream this process for you with various level PDF security.

    www.bottomline/dynamics

     

     

    Jon Rivers

    Data Masons Software, LLC.

    Phone: 866-575-1631 x973

  • Rajdip Das
    I have to generate payslip as report and save into a pdf. After creating pdf then it would be sent to the employee via e-mail. I have to incorporate a password protection of each payslip pdf files. Only user will know the password and then they only can the open file by entering selected password.

    You could also compress the pdf into a zip archive with a password and email this archive.

  • Hi Gl00mie,

    Thanks for reply. Can you tell me the procedure of create ZIP Achieve and set password into it under DAX environment? If it is done then my problem will solve.

     

    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com

  • There are tons of zip (i.e. implementing Deflate algorithm) compression libraries. For instance I've found SharpZipLib - free library that supports zip/bzip2/gzip formats (including creation of password-protected zip-files) and ships with complete source code.
  • Hi Gl00mie,

    Thanks again for your reply. I am trying to do this. If arises problem then  i'll let u know.


    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com

  • Hi everybody,

    I have the same problem with Rajdip.

    Is anyone solve this problem without using a rar application.

    I think this belongs to PDFViewer class in Ax. but i could not find a solution :(

  •  Hi,

    Till now I didn't get any solution regarding this process. If you find any solution then please let me know. Any suggestion would be helpful.

    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com

  • Hi,

    I do face the same problem, if anyone find the soln plz do let me know.

     

    Thanks 

    Chaya

  • Till today, after lots of R&Ds, it has not done....

    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com

  • Hi Rajdip,

    please share the code for the same ... i also have to generate a payslip in 2009 and that must be password protected.

    thanks

  • Sorry guys, I could not help any more cause still we are finding the solution from Ax end. We could not make it till today but one way I can give you, it may help you but not sure how much it will help; make your document in word format and make this document  password protected with the help of 3rd party software or may be help of wrapper class of Ax and then convert into the document in pdf. I am not sure about this process but conceptually it can be done. Best of luck and happy DAXing.

    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com

  • In short, you have to use from .NET to write a managed code or custom assembly in order to protect the given PDF  with password, then call it from your x++, run it as a job or call it within your current x++ class with the required args.

    If your are working with SSRS, the logic is the same, except you could write the managed code directly inside SSRS and no need to x++ (but and unless you might use x++, depends on your situation).

  • Absolutely agree with Kambiz, do a .dll with the logic and incorporate the password in the document and convert it to into the .pdf.

    For SSRS, I think there must have this option because .NET is a great and powerful tool. Check it once from there.

    Cheers... happy DAXing... :)

    With Regards

    Rajdip Das - Kolkata

    http://dax-world.blogspot.com