- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-09-2022 10:14 AM
I'm trying to replace a comma for a dot in a currency field but I'm failing with the script
This is the script
function onChange(control, oldValue, newValue, isLoading, isTemplate) {
if (isLoading || newValue === '') {
return;
}
var contractCost = g_form.getValue('u_contract_cost');
var dot = contractCost.replace(/,/g, '.');
g_form.setValue('u_contract_cost', dot);
}
This is the field and the error that is returning
Solved! Go to Solution.
- Labels:
-
Contract Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-11-2022 01:28 PM
IT is probably down to your browser or users Locations. This is the probable solution.
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0830639
Let me know if this works.
Please mark as Helpful/Correct if helpful.
Regards
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-11-2022 01:28 PM
IT is probably down to your browser or users Locations. This is the probable solution.
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0830639
Let me know if this works.
Please mark as Helpful/Correct if helpful.
Regards
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-12-2022 05:38 AM
It was exactly this.
Thank you, Paul.