Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
590
checkbox oncheckchanged event use for javascript
posted

Hi team,

Thanks for great support all your Queries,

i have one query like i have webdatagrid in Itemtempleatefield. 2 check box's i am try to use it for oncheckedchange() event in javascript but getting error.

aspx code :

<asp:TemplateField HeaderText="Document Report(In/Out)">
                                                                    <ItemTemplate>
                                                                        <asp:CheckBox ID="chkfeed" CssClass="tableElement" runat="server" OnCheckedChanged="test();" />
                                                                        <asp:CheckBox ID="chkdply" CssClass="tableElement" runat="server" />
                                                                    </ItemTemplate>
                                                                    <ItemStyle CssClass="gridViewTblColumns" Width="15%" HorizontalAlign="Center" />
                                                                    <HeaderStyle BackColor="#EBEBEB" HorizontalAlign="Center" />
                                                                </asp:TemplateField>

Javascript function:

<script language="Javascript" type="text\javascript">

function test()

{

alert("Hi");

}

</script>

please share how to use it for check box in javscript.

Thanks

Ranganathan palanisamy