- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 03:17 AM
Hi All,
I have to validate whether user has added an attachment or not before allowing him to submit a request.Please help me if any of you have done a similar kind of implementation.
Regards,
Kirti
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 04:59 AM
Write the below on submit script
function onSubmit() {
var attachmentList = gel("header_attachment_list_label");
if (attachmentList)
{
if (attachmentList.style.visibility == "hidden" || attachmentList.style.display == "none")
{
alert("Please attach the required file.");
return false;
}
}
}
Regards,
Harish.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 05:12 AM
Make the answer correct . Your welcome.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 05:12 AM
if you are okay with the solution that's alright ...
But just a caution , gel is not recommended by service now .... might work now but might not work later once you upgrade your instance ...
decision is your's to take
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 05:14 AM
Hi Kalaiarasan,
Oh so this doesnt work in Eureka well in that case i should avoid this.
Thanx for cautioning me
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 05:17 AM
should work in Eureka ... i was referring upcoming version's ...
check once on demo if your instance isn't on Eureka
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2014 05:20 AM
Hi Kalai,
im using Dublin it works for me.
Regards,
Harish.