I need to format TextBox <asp:TextBox runat="server" id="txtValor" MaxLength="20"></asp:TextBox
and I am very difficult, first this grid is opened in a modal, that is, when I create the main page I can not get control by javascript and put the mascara, have not been initialized.
I need to do this formatting only when I open this modal and load this grid, how can I perform this formatting for decimal field?
<asp:UpdatePanel runat="server" ID="upnVincGridFuncionarios" RenderMode="Inline" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView runat="server" ID="gdvVincFuncionarios" Width="100%" OnRowDataBound="gdvVincFuncionarios_RowDataBound">
<Columns>
<asp:TemplateField>
<HeaderTemplate>
<asp:Label runat="server" ID="lblNameHead" Text='Nome'></asp:Label>
</HeaderTemplate>
<ItemTemplate>
<asp:Label runat="server" ID="lblNameEmployee" Text='<%#DataBinder.Eval(Container.DataItem, "Name") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="Msisdn" HeaderText="Celular" HeaderStyle-HorizontalAlign="Left" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField DataField="Cpf" HeaderText="CPF" HeaderStyle-HorizontalAlign="Left" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField DataField="NumRegistration" HeaderText="Matrícula" HeaderStyle-HorizontalAlign="Left" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField DataField="CostCenter" HeaderText="Centro de Custo" HeaderStyle-HorizontalAlign="Left" ItemStyle-HorizontalAlign="Left" />
<asp:TemplateField>
<HeaderTemplate>
<asp:Label runat="server" ID="lblValorHead" Text='Valor'></asp:Label>
</HeaderTemplate>
<ItemTemplate>
<span style="display: none">
<asp:Label runat="server" ID="lblVincIdEm" Text='<%#DataBinder.Eval(Container.DataItem, "IdEm") %>'></asp:Label>
</span>
<asp:TextBox runat="server" id="txtValor" MaxLength="20"></asp:TextBox>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
</asp:UpdatePanel>