Get values from a textarea on UI Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-11-2024 06:56 AM - edited ‎10-11-2024 07:09 AM
Hello everyone!
I have an issue with my textarea on the UI page. I need to create a GlideModal with some fields for the user to update them if he needs it, but on the description field I'm required to have a textarea field. The problem is I can't get that value and I need to confirm if description the field is empty or not before updating, if it's empty I don't want to update the form. The other fields are all working except the textarea one. The processing script is attached here as well with the hmtl script and the GlideModal. Can anyone help me with this please?
Thank you!
Joana Fernandes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2024 07:49 AM
Can you share code of how DescriptionValue is defined and mapped with the html field?
Follow the same logic you followed for the other fields,I can see resolutionInfo is properly mapped.
Refer below link on how to get value from your HTML field value into Processing Script.
Mark it helpful if this helps you to understand. Accept solution if this give you the answer you're looking for
Kind Regards,
Rohila V
2022-25 ServiceNow Community MVP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-14-2024 01:07 AM
Hi @Voona Rohila !
The html code is showed on one of the screenshots I sent. I don't have DescriptionValue defined inside the html, only on the processing script and the client script. I'll look into the link to sent to see if it'll fix!
Best wishes,
Joana Fernandes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-14-2024 02:08 AM
@Voona RohilaI fixed the issue, the textarea has a white space it doesn't start with an empty value, so I had to use the trim() to get the function to work! Thank you for your help!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-14-2024 09:00 AM
Glad to help,If my response helped please mark it correct and close the thread so that it benefits future readers.
Mark it helpful if this helps you to understand. Accept solution if this give you the answer you're looking for
Kind Regards,
Rohila V
2022-25 ServiceNow Community MVP