Surjeet
Surjeet

Reputation: 21

postscript example to reset form fields using pdfmarks

I am trying to reset the form fields (on a button click) created using PDFmarks in the post script, I have tried the samples shared in the pdfmarks reference manual with no luck (after distling through acrobat it does not do so). Could someone please share a sample or let me know what i am doing wrong

My sample code is :-

[ /_objdef {field5} /Subtype /Widget
/Rect [213.111 434.362 243.111 416.362]
/F 4
/V (Select Option)
/T (Clear)
/TU (Clear Form)
/FT /Btn 
/F 1 % field visible but not printable 
/DA (/TiRo 10 Tf 0 g )
/MK<</BC [ 1 0.5 0.5 ] /BG [ 0.75 0.45 0.75 ] /CA (Clear) /AC (Done!)/R     180>>
/BS<</W 3/S /I>>
/A << /S /ResetForm >>
/Ff 65536
/A << /S /ResetForm>>
/ANN pdfmark
[ /Obj {field5} /StOBJ pdfmark

Upvotes: 1

Views: 138

Answers (1)

Surjeet
Surjeet

Reputation: 21

Issue got resolved, NeedAppearances=true flag in the acroform dictionary was not set due to which reset button was not displaying correctly and reset form action was also not getting executed (interestingly text and combo fields were working fine even without this flag)

Upvotes: 1

Related Questions