We're reclaiming inactive PDIs to keep them available for active builders. Learn what's changing, who's affected, and how to protect your work. Read More

If caller's email id (use custom field)

TanujB
Tera Contributor

. If caller's email id (use custom field) description is empty, then while submitting form will display an error message and it will not submit.  I am stuck in this please provide a answer for this

2 REPLIES 2

J Siva
Kilo Patron

Hi @TanujB 
You can achieve this via either onChange or onSubmit client script.
Share the script which you've written.
It'll help us to debug.
Regards,

Siva

glideFather
Tera Patron

Hi @TanujB,

 

this is a draft of client script onSubmit:

(not tested, you need to validate)

function onSubmit() {
var yourField = g_form.getValue('field_name'); //rename field_name
    if (!yourField) {
        g_form.showFieldMsg('yourField', 'Field is required before submitting.', 'error');
        return false; // submission is aborted
    }
    return true; //submit ok
}


Replace field_name with your field name


✂-----Cutting-out-the---✦AI-noise✦---All-replies-written-and-vouched-for-by-GlideFather---