Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!
![]() |
JavaScript "K" Event |
Post Reply
|
| Author | |
JohnT
Team Player
Joined: 23 Oct 13 Location: United States Status: Offline Points: 30 |
Post Options
Thanks(0)
Quote Reply
Topic: JavaScript "K" EventPosted: 23 Dec 13 at 2:58PM |
|
I'm trying to determine if my JavaScript is the problem or the "K" event for the FormFieldJavaScriptAction works differently than expected. My understanding is that the form field "K" event should fire after any keystrokes.
Given the code below, the event does not fire on the initial non-numeric keystroke. After that point it fires. Obviously, the intended behavior is to have this event fire right after ANY non-numeric key is pressed. Thanks, John
DPL.AddGlobalJavaScript('JTJava2', 'function numcheck(){parseInt(event.value); if ((isNaN(event.value) || event.value <= 0) && event.value != "") {app.alert("Please enter only numbers",3,0,"Number Check"); event.value = "";}}'); ... DPL.FormFieldJavaScriptAction(QTYFld, 'K','numcheck()'); |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |
Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. About — Contact — Blog — Support — Online Store