Hi, I am trying to update a textfield when the select is changed using javascript event onchange, so How I can do that? Which is the best practices here?
Here is my code, any Ideas? <script type="text/javascript"> function getVolumenInicial() { var volumenInicial = document.getElementById('save_volumenInicial'); var maquinaSelected = document.getElementById('save_maquina_codigo'); volumenInicial.value = '%{maquinas[' + maquinaSelected.selectedIndex + '].metro}'; } </script> ..... <s:select label="MÃÂáquina" name="maquina.codigo" list="maquinas" onchange="getVolumenInicial();" value="%{maquina.codigo}" required="true" listKey="codigo" listValue="codigo" /> <s:textfield label="Volumen Inicial" name="volumenInicial" value="%{venta.volumenInicial}" readonly="true" size="7" maxlength="9" /> -- View this message in context: http://www.nabble.com/javascript-update-tag-value-property-tf4843331.html#a13856511 Sent from the Struts - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]