Pop-BOX
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-29-2024 04:06 AM
when I click on Submit button a pop box should come which contains the user Title .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-29-2024 05:50 AM
You can use UI Page for it
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-29-2024 06:18 AM
can I get the solution for it :-
function getReference(id) {
// Get reference to the element with the specified ID
return document.getElementById(id);
}
function onSubmit() {
// Use the getReference method to retrieve the element
const callerTitleElement = getReference("callerTitle");
// Access the value or provide a default message if the element is not found
const title = callerTitleElement ? callerTitleElement.value : "No Title provided";
alert("Caller Title: " + title);
}
when I use this get the error in Service now is it possible for you to make it correct
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-29-2024 11:11 PM
What kind of error you are getting?? and what you want to achieve can you please explain a little?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-30-2024 12:00 AM
Hi @aggarwaltan ,
You can use below script:
function onSubmit() {
g_form.getReference('caller_id',function(caller){
if(caller && caller.title){
alert("Caller titile:"+caller.title);
}else{
alert('No caller title');
}
});
return true;
}
Mark it as helpful and solution proposed if it serves your purpose.
Thanks,
Anand