g_form.setValue is not setting value for a Integer-data type field through Client Script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-24-2020 09:23 AM
Hi,
I am unable to set the value of a field whose data type is Integer through Client script. The field is blank when the Client script runs. Anyone faced this issue?
Below statements did not work-
g_form.setValue('integerDataTypeFieldName', 75);
OR
var a = parseInt(75);
g_form.setValue('integerDataTypeFieldName', a);
Thank You!
- Labels:
-
Request Management
-
Service Catalog

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-24-2020 09:26 AM
make sure field backend name is correct. can you add some screenshot ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-24-2020 09:43 AM
Yes sure ...
My onChange Client script- (Please note the Script include just returns the value held by all the fields I included in the variable 'fields' Line 7)
The alert which confirms my client script is receiving the number "78" for the field "u_percentage_of_work"
The back end field name matches-
But Integer field is auto-populated with empty value-

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-24-2020 09:51 AM
just confirming , on your client script rest of the other field has been populated only "u_percentage_of_work" field has not set ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-24-2020 09:57 AM
Yes correct