Home > Forum > Rules, JS, SQL > Get ID of form field that triggered function

Get ID of form field that triggered function
0

Hi,

I would like to programmatically get the ID of the form field that triggered a function. How can I do this? The end goal is to set the form field back to its default value in case javascript validation fails.

Thanks!
Mark

In reply to: Martin Meze (Freelancer)

Hi Mark,

Can you elaborate a bit more in details? Sometimes in Webcon you can achieve the same result in different ways. If you provide more info I can try to provide a solution. :)

Cheers,
Martin

Hi,

Like I said, I am performing a field validation with javascript if a field has changed. I need to get the field ID of field that triggered this function, so if the validation fails, the field can be set back to its default value. I have been experimentin with uxContext parameter, but have been unable to find a function or value, that carries the ID of the field that triggered the function.

Best regards,
Mark

Did you know that with WEBCON you can automate virtually any process? Even baking cookies 🍪
 
Speaking of cookies: we use the ones that are essential for our website to function properly, as well as additional ones that help us customize our content to your preferences. If you don’t mind cookies, click Accept. If you want to learn more, explore settings.
Settings