Subject: Passing the IndexId to JaveScript
From: "Ken Holzer" <[EMAIL PROTECTED]>
===
I have the following code where I am using the nested:iterate tags and need
to pass the indexid to a javascript in order to set the value of another
field.
I am not sure how to pass the index id.
Here is the code:
function setUpdated(idx)
{
document.forms[idx].isUpdated.value="1";
}
<nested:iterate property="inventoryList" indexId="idxInv">
<TR VALIGN="MIDDLE">
<TD ALIGN="left">
<nested:text property="invDesc" size="50" maxlength="50"
onchange="setUpdated(<%=idxInv %>)"/>
</TD>
<TD ALIGN="left">
<nested:text property="invSize" size="10" maxlength="50"
onchange="setUpdated(<%=idxInv %>)"/>
</TD>
<TD ALIGN="left">
<nested:text property="invColor" size="10" maxlength="50"
onchange="setUpdated(<%=idxInv %>)"/>
</TD>
<TD ALIGN="left">
<nested:text property="invQuantity" size="5" maxlength="4"
onchange="setUpdated(<%=idxInv %>)"/>
</TD>
<TD ALIGN="left">
<nested:write property="isUpdated"/>
</TD>
</TR>
</nested:iterate>
I am trying to set the isUpdated property so that I know when a row has been
changed and on the update I will then only update the rows that were
changed.
Any help would be appreciated,
Ken Holzer
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>