cancel
Showing results for 
Search instead for 
Did you mean: 

Delete scripts from generated PDF document

frankhoelscher
Discoverer
0 Kudos

Dear experts,

We are using FormCalc in our PDF quotations templates to hide lines with no value.

The problem we see it that the final generated PDF quotation we send to the customer still contains this scripting.

Every time the PDF is opened the scripting is started.

If the user has not a 100% compatible PDF viewer like the Adobe Reader or he has switched off the usage of scripting in the settings, the line we want to hide from the customer are shown again.

This is very bad, if we hide the discount field because we do not want to give discount to the customer. 😉

Do you know any way to ensure that the final PDF files generated by the ADS do not contain active scripting?

Thank you.

Best regards,
Frank

Accepted Solutions (0)

Answers (1)

Answers (1)

Florian
Active Contributor
0 Kudos

Hi Frank,

I'm not sure if I get your problem correct, because you didn't share that much details.

Is your form marked as an offline-form?

Is it a hole line you want to hide? Screenshot would be appriciated

What event you are using to hide the lines? Form-ready?

Anyway, I do not see a reason why you need to hide lines via scripting. Just put all your lines into a table and do a loop with it. So there will be no empty lines between. I always prepare my data via the driver-program or if it is not possible there (because of a SAP-original) I do it via the interface.

~Florian

frankhoelscher
Discoverer
0 Kudos

Hi Florian,

I will try to give some more details.

The form is set as "Static PDF Form"  in Form Properties>Server.

Do you mean this setting with "Offline-Form"?

Take as example the line 2 in the sums table for "Product-Discount":

If the user does not give discount in the quotation, we want to delete this line from the sums table.

We do this by a FormCalc script for this table line.

But this script remains in the PDF after it was created by the ADS.

So when we send this PDF to a customer which does not use Adobe Reader or has switched of scripting he sees the empty discount line again. This is not good...  😉

Could you explain in more details how you would fill for example this sums table by your method?

The lines "Product-Discount", "Project-Discount", "Freight Charges" and "Tax" can have values or not. They should be hidden, if they do not contain a value.

Thank you.

Frank

Florian
Active Contributor
0 Kudos

Have you already tried to run your script just on the server? Normally I do set this option. Maybe it's just that easy, because I never faced a problem like that and I do a lot of form-developing.

~Florian

frankhoelscher
Discoverer
0 Kudos

Hi Florian,

Sorry for the late answer. But we are struggling with the template design after we have finished our SAP CRM EHP3 upgrade. Every time I create a new template the webservice is deleted as soon I save uploaded template file. Strange issue....

Therefore I can not proof my experience of the "Run at" setting at the moment.

But as I remember from my SAP Adobe training last year the setting has no impact. This I was told by the trainer. Our own tests some time ago showed the same result.

Regards,

Frank