- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-18-2022 05:09 AM
Hi everyone,
Is it possible to add the minimum characters required to the catalog field of variable type multi-line text?
Eg: I want a user to at-least write 30 characters before submitting.
Regards,
Priya
Solved! Go to Solution.
- Labels:
-
Service Catalog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-18-2022 05:57 AM
Use onSubmit()/onChange() catalog client script as per your requirement.
function onSubmit() {
if(g_form.getValue('<multi_line_variable_backend_name>').length < 30){
g_form.showFieldMsg('<multi_line_variable_backend_name>', 'Enter at least 30 characters.', 'error', true);
return false;
}
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-18-2022 09:46 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-18-2022 09:48 PM
Hi,
We can apply for single line text variables not for multiple line text variables.
Thanks,
Pavankumar
ServiceNow Community MVP 2024.
Thanks,
Pavankumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-18-2022 09:52 PM
Hi Pavan,
Thank you so much!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-18-2022 11:53 PM
Hi,
Please select correct response so future readers will check that solution.
You marked incorrect which will not work for Multi-line text as per your requirement.
Thanks,
Pavankumar
ServiceNow Community MVP 2024.
Thanks,
Pavankumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-19-2022 12:50 AM
Hi,
Thank you Pavan!!
Regards,
Priya