<%! int i;>
<% i=0; %>
<input type="text" id="itemValue" onchange=changeValue('<%=i%>')>
it works fine if i give alert(i) in
Otherwise it gives error i is undefined.
Please help me. I don't want to bother user by increasing one user click.
Please help what is the reason ???
Well I suppose this has become a Struts question. Anyways, I don't know much about Struts 1.2, but looking at this reference I think you can use indexId attribute to specify a name for a bean that will contain the index of the current iteration which you can use instead of the scripting (you also mentioned that you used indexed property of iterate tag, maybe you made a typo or something)...