Calling Button Mouse Up Javascript Function from BeforeSave Javascript

Forum for the PDF-XChange Editor - Free and Licensed Versions

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Post Reply
jono
User
Posts: 2
Joined: Thu Jul 02, 2020 6:29 pm

Calling Button Mouse Up Javascript Function from BeforeSave Javascript

Post by jono »

I'm looking to create a form that will automatically validate the form in two ways:

1) Manually by the user as the form is being filled out if they press a button
2) Prior to saving.

To solve this, I thought of creating a button mouse up JavaScript function that would be triggered when the user presses the button.
Instead of creating a copy of that function in the Before Save JavaScript I'm looking for a way to call the MouseUp function.

Is something like this possible?

Or can I create a JavaScript function that exists in a common area but is then called for both MouseUp and BeforeSave events?

Thank you,

Jono
jono
User
Posts: 2
Joined: Thu Jul 02, 2020 6:29 pm

Re: Calling Button Mouse Up Javascript Function from BeforeSave Javascript

Post by jono »

Continuing to look through to documentation, but can't seem to find anything.

I guess what I'm asking is can one javascript function be called or linked to from multiple places in the PDF?
Or do we need to copy the same JavaScript function to multiple JavaScript script locations to get the same behaviour?

Thanks,

Jono
Post Reply