There are no methods for directly adding images or text objects. As you mentioned, you can use form field, and you can also use text and stamp annotations. What is the problem with flattening?
I will be adding digital signature fields in the document too.
Have decided to add a text field, then flatten then add the digital signature field, that will solve the add text issue.
The only problem to remain is to replace an image, is this possible with scripting?
I need to replace the old logo with a new logo and this will be a repeated process.
Any help will be most appreciated.
Thank you George.
Thank you George, that was exactly what I needed.
- I added a button field
- Changed the colour to white,
- Changed button position to icon only (this step is important otherwise will not work)
- Button importIcon
- Then flatten
Script as follows for reference:
var f = this.getfield("logobutton");
f.fillColor = color.white;
f.buttonPosition = position.iconOnly;