I have a VF page with file upload control ,Users will upload PDF file along with other details and the file will be stored in Attachments.

Requirement : When user uploads PDF then file should be Water Marked with some text OR some custom text should be included in the header/footer of the file and saved in Attachment object.

What are the options available to acheive this functionality ?



You can't edit the PDF file as this is a binary content. Apex is missing that capability. You have to either build a custom solution outside Salesforce and use it as webservice or you can try some online solution like aspose.com.

  • Thanks for your response, I won't be able to use Aspose in my case due to the licensing cost. Do you have any pointers on the other option ( Reading watermarked PDF from external web service and update in attachment object ) Nov 22 '16 at 0:28
  • If you know Java you can use iText to create your own web service. Also Heroku may be a good option here.
    – Saroj Bera
    Nov 22 '16 at 4:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.