You need to sign in to do that
Don't have an account?
tiran
Javascript in PDF
Hello everyone.
I came acrosee a problem,that is:
I created a page,renderAs="pdf",then in components,i got all datas to the body part. So,the result is when i click un button in the opportunity,i can get a pdf.
But my chef ask me to add the javascript that can call a mouse events when passing a url in the PDF.
I want to know that it is possible to implement this funtion or not? and how?
Thank u !
You can't change anything in the body, as its not an HTML page, its a PDF.
All Answers
You can't have javascript in a PDF, as that isn't part of PDF and thus won't be supported by the reader.
Thank ur anwer.
But when i passing the url,in the pdf,will show its address of url , it is possible to change the content in that part ?
The URL is simply a locator for the PDF page. The only thing you can change is the address.
that says i cannot change anything in the white part?
You can't change anything in the body, as its not an HTML page, its a PDF.
Here is what I did and hope it helps someone:
Create a normail VF page with all JS logic you like. Have an iFrame that will point to the PDF page. This is even better, as you have more control over it, if you are passing parameters to embedded PDF page.