日期:2014-05-18 浏览次数:20495 次
function addshow(obj) { var count= parseInt("<%=this.Repeater1.Items.Count%>") for (var i=0;i<count;i++) { document.getElementById('PayPrice'+i).value=obj; } } <asp:Repeater ID="Repeater1" runat="server"> <ItemTemplate> <tr> <td align="left" background="../IMG/Order_bg_2.gif" ><asp:TextBox ID="PayPrice" runat="server" Width="9px" Text='<%#Convert.ToDouble(Eval("Price").ToString()).ToString("N0")%>'></asp:TextBox></td> </tr> </ItemTemplate> </asp:Repeater> obj的值变动时无法传到Repeater1控件里面的PayPrice.text里面。