How do you change a field's value to the None choice in script?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-21-2013 12:32 PM
http://wiki.servicenow.com/index.php?title=Customizing_Choice_Lists#Values_Associated_with_.22None.22_option
says that the "None" option does not have a sys_choice record associated with it. I tried setting the field to following values but they all failed to become None.
- '' (empty string)
- '0'
- 0
- null
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-21-2013 12:45 PM
The following for me, in a Client Script, set the Category field to "-- None --"
g_form.setValue("category", "");
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-21-2013 12:46 PM
The following also worked:
g_form.clearValue("category");
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-21-2013 12:54 PM
What if you are not using GlideForm? How about GlideRecord?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-21-2013 12:54 PM
What if you are not using GlideForm? How about GlideRecord?