hello
i have a PDF file opened that has several tick boxes
what i want to do is to insert/remove a page(s) depending on the state of that tick box
is there any way to detect a change to a form field returning information about what has changed
many thanks
detecting change to a form field
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- Site Admin
- Posts: 19913
- Joined: Mon Jan 12, 2009 8:07 am
Re: detecting change to a form field
Hello Joe,
You will need to have a script that listens for events for the particular field (that check box), and when an event is fired - use the isBoxChecked method, but I am not quite sure whether this is currently supported in our SDK - so I have asked for some help from the dev team.
Cheers,
Stefan
You will need to have a script that listens for events for the particular field (that check box), and when an event is fired - use the isBoxChecked method, but I am not quite sure whether this is currently supported in our SDK - so I have asked for some help from the dev team.
Cheers,
Stefan
-
- Site Admin
- Posts: 2448
- Joined: Thu Jun 30, 2005 4:11 pm
Re: detecting change to a form field
Hi, joe.
In the new build(upcoming) you will be able to intercept the new event:Wait for the new build and look to the updated SDK help, [Reference/NamedItems/Objects/Notifications/FieldChanged].
Best
Regards.
In the new build(upcoming) you will be able to intercept the new event:
Code: Select all
eventhandler OnEvent(type, name,....)
{
if ((type == PXCVA_OnNamedNotify) AND (name == "Notifications.FieldChanged"))
{
string fn;
ctrl.GetProperty("Notifications.FieldChanged.Name", fn, 0);
string js = "var f = this.getField(" + fn + "); if (f != null) { f.value; };";
string newVal;
ctrl.RunJavaScript(js, out newVal, ...);
....
}
}
Best
Regards.
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 89
- Joined: Wed Dec 29, 2010 8:50 am
Re: detecting change to a form field
fantastic cant wait to get my hands on it
thanks
thanks
-
- Site Admin
- Posts: 7370
- Joined: Wed Mar 25, 2009 10:37 pm
Re: detecting change to a form field
HI Joe,
look for it mid January.

look for it mid January.

Best regards
Paul O'Rorke
PDF-XChange Support
http://www.pdf-xchange.com
Paul O'Rorke
PDF-XChange Support
http://www.pdf-xchange.com