Dynamic value in template

surya123
Mega Guru

Hi All,

 

I am using HR document template. What we want to do is, if a value on field is xyz, then show text as ABC or else show DEF. Is this something we can achieve ?

 

 

 

Thanks

Surya

1 REPLY 1

Akshata jamdar
Mega Guru

Hi surya,

 

You can do this using client script. You can write onChange client script,

var name_of_variable=g_form.getValue("Field_name");

if(name_of_variable=='xyz')

{

g_form.setValue("Field_name","abc");

}

else

{

g_form.setValue("Field_name","def");

}

you can do this through script with the help of template it is not possible.

 

Mark the answer as correct and helpful if it will help you in any manner.

 

Regards,

Akshata