PDF Forms: problem with keypad "decimal dot" when filling "number" fields

Ok, here's my problem :
I've created a form with fields. My client want to input in those fields amount of money. So I've created fields formatted with the "Number" category. 2 decimals, "1234,56" separator style, not currency symbol. So far, so good!
When testing out the form, here's what happening :
On the computer that I've created the form (iMac, Acrobat Pro and Reader, french canadian keyboard layout and system)
Using the keypad, I can input numbers, with the "decimal point" from the keypad no problem.
But when the client is trying to to the same on his PC (and the same is happening with my PC at home, Acrobat Pro 9.2, french canadian keyboard layout and system), I CAN'T use the "decimal point" keypad key to input numbers (like 43,25). It's just not working (error sound). I can however use the "dot" on the keyboard near the "M" key, but the client don't want to do that.
Why is it working on the Mac, but not on the PC's!?
So far, the only workaround that I've found is to set the "money" fields categories to "none" instead of "number.

It is a little bit tricky, but you might have to add your own formatting handler. You would proceed as follows:
1. Set the Format to "none".
2. Add the following script to a Custom Keystroke event:
if (event.change.length > 0 && event.willCommit == false) {event.change = event.change.replace(/\,/gim, ".") ;
3. Add the following script to a Custom Format event:
event.value = event.value.toString().replace(/\./gim, ",") ;
And that should take care of the situation.
Note that i have not tested the scripts, and there may be a chance for bugs.
The advantage of this solution is that internally, you will have the correct format for a number, so that calculations will be correct.
Hope this can help.
Max Wyss.

Similar Messages

Maybe you are looking for