Can event component change field value of another component?

How to change a text field value based on a dropdown selection in ChronoForms.

Overview

The issue occurs when trying to use the built-in Events dropdown to directly update another field, which is not supported.
Set the event Action to 'function', specify the function name, and define the function within a Load JavaScript action to update the target field value.

Answered
ca calangoloco 05 Dec, 2014
Hi @ll!

It is possible to change the value of a dropdown change the field value of a textbox?

I thought about using the Events dropdown, but did not work:


Thanks in advance
Max_admin Max_admin 06 Dec, 2014
Answer
Hi calangoloco,

Yes, but not this way, you need to set the "Action" to "function" and enter the function name in the "fn()" box, then define your function into a "Load JavaScript" action:


function changeValue(){
jQuery("#field_id").val("xyz");
}


Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
This topic is locked and no more replies can be posted.