Copy link to clipboard
Copied
Hello all, please I need someone to assist me in looking at the following currency script for Naira, I have searched and tried several approaches but don’t know why am not getting the right result in my form, the following is the script I picked from Thom_Parker's post on the same topic, from the following link: https://acrobatusers.com/tutorials/formatting_text_fields/, but it still did not work on my form.
event.value = String.fromCharCode(0x0A3) + event.value;
which by the above script description the following should give me the Naira currency symbol i need:
event.value = String.fromCharCode(0x20A6) + event.value;
but instead, i get a bullet circle symbol on the field. i have used three different font type: "Open Sans", "Helvetica", and "Arial" but none of them gave me the sign, i have equally worked another clean page with a singular form field, yet i got the same result.
The following picture is how my currency symbol should look like this:
Please i will appreciate any support in this direction. Thanks!
Use this code:
if (event.value) event.value = "\u20A6" + util.printf("%,0.2f", event.value);
Copy link to clipboard
Copied
Use the Unicode value, like this:
event.value = "\u20A6" + event.value;
Copy link to clipboard
Copied
Thank you so much try67, am very grateful for your response, but i have entered this script and it is still not giving me the symbol, instead i get a bullet circle sign like the picture below:
this is exactly how i entered the script in the custom format page below:
please is there anything I am not doing right here?
i have equally used this:
event.value = String.fromCharCode(0x20A6) + event.value;
but still it didn't work.
Copy link to clipboard
Copied
For the field use a font like Arial.
Copy link to clipboard
Copied
Hi, Bernd_Alheit, i have equally tried Arial, it still didn't work.
Copy link to clipboard
Copied
Then the font you're using doesn't support unicode properly. I tried it with Helvetica and it worked fine:
Copy link to clipboard
Copied
Thank you so much Bernd_Alheit and try67, i so much appreciate all the responses, but could there be something i am mixing up here, because its still not working, i have just tried the same thing on a clean page, it still turned out the same bullet sign, here is my attachment of entire property page of what i did and the main adobe page itself:
please i still need your assistance on getting this done, thank you so much for your kind responses.
Copy link to clipboard
Copied
It works with font Arial:
Copy link to clipboard
Copied
Thank you so much Bernd_Alheit, but here is my screen and what i did:
And for the custom script here is Format page:
could there be something i am missing here, i have done everything i have learned from everyone.
Copy link to clipboard
Copied
Thank you so much Bernd_Alheit, and try67, it has now worked, I used Tahoma font-type and it worked, but there is one more thing here, please how can I introduce separator to the figures, instead of straight digits as it is now, I will like it to read as amount with commas, like N10,000.00 instead of N10000, please I need help to fix that. Thank you so much.
Copy link to clipboard
Copied
Use this code:
if (event.value) event.value = "\u20A6" + util.printf("%,0.2f", event.value);
Copy link to clipboard
Copied
Excellent, it worked perfectly, thank you so much try67, i am very grateful for all your support in this, thanks a lot.