S
Sjaakie Helderhorst
Hello all,
I'm having some problems with data in a template column.
The column...
<asp:TemplateColumn HeaderText="Amount">
<HeaderStyle Width="75px"></HeaderStyle>
<ItemStyle Font-Size="10px" HorizontalAlign="Left"
BackColor="White"></ItemStyle>
<ItemTemplate>
<asp:TextBox ID="txtAmount" BorderStyle="Solid" Width="40"
TextMode="SingleLine"
Runat="server" MaxLength="5" Text='<%# DataBinder.Eval(Container.DataItem,
"Amount") %>'
Font-Size="11px" onKeyUp='checkNumericInput(this); setAmountTotal(this,
<%# DataBinder.Eval(Container.DataItem, "NumberOfItemsInPackage") %>);'
onKeyDown="checkCursorKeyPress(this);" onFocus="setCurrentAmount(this);"
onBlur="updateCurrentAmount(this)" />
x <%# DataBinder.Eval(Container.DataItem, "Inhoud") %>
</ItemTemplate>
</asp:TemplateColumn>
On onKeyUp 2 Javascripts are triggered which check if value is numeric and
calculates total of input value times the number of items in package.
Problem occur with: setAmountTotal(this, <%#
DataBinder.Eval(Container.DataItem, "NumberOfItemsInPackage") %>);'
Somehow onKeyUp='checkNumericInput(this); setAmountTotal(this, <%#
DataBinder.Eval(Container.DataItem, "NumberOfItemsInPackage") %>);'
isn't parsed to a value. The source-code of the rendered page looks like:
onKeyUp="checkNumericInput(this); setOrderTotal(this, <%#
DataBinder.Eval(Container.DataItem, "Inhoud"
%>);"
Can anyone explain why this is happening?
Thanks!
I'm having some problems with data in a template column.
The column...
<asp:TemplateColumn HeaderText="Amount">
<HeaderStyle Width="75px"></HeaderStyle>
<ItemStyle Font-Size="10px" HorizontalAlign="Left"
BackColor="White"></ItemStyle>
<ItemTemplate>
<asp:TextBox ID="txtAmount" BorderStyle="Solid" Width="40"
TextMode="SingleLine"
Runat="server" MaxLength="5" Text='<%# DataBinder.Eval(Container.DataItem,
"Amount") %>'
Font-Size="11px" onKeyUp='checkNumericInput(this); setAmountTotal(this,
<%# DataBinder.Eval(Container.DataItem, "NumberOfItemsInPackage") %>);'
onKeyDown="checkCursorKeyPress(this);" onFocus="setCurrentAmount(this);"
onBlur="updateCurrentAmount(this)" />
x <%# DataBinder.Eval(Container.DataItem, "Inhoud") %>
</ItemTemplate>
</asp:TemplateColumn>
On onKeyUp 2 Javascripts are triggered which check if value is numeric and
calculates total of input value times the number of items in package.
Problem occur with: setAmountTotal(this, <%#
DataBinder.Eval(Container.DataItem, "NumberOfItemsInPackage") %>);'
Somehow onKeyUp='checkNumericInput(this); setAmountTotal(this, <%#
DataBinder.Eval(Container.DataItem, "NumberOfItemsInPackage") %>);'
isn't parsed to a value. The source-code of the rendered page looks like:
onKeyUp="checkNumericInput(this); setOrderTotal(this, <%#
DataBinder.Eval(Container.DataItem, "Inhoud"
Can anyone explain why this is happening?
Thanks!