R
Rob
It might be a simple question.
I am very new to ASP.Net 2, and stuck with a problem.
How can I execute a client side JavaScript function on CheckBox click.
I am able to execute function at server, But I don't know how to validate at
client side before going to server.
This code is within a GridView
<ItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server"
Checked='<%# Bind("OpenConnection") %> '
Enabled="True"
OnCheckedChanged="OpenConnection_Clicked" AutoPostBack="True" />
</ItemTemplate>
When I put onClick="Javascript:FunctionName" within the tag, it says:
Validation (ASP.Net): Attribute'onclick' is not a valid attribute for
element 'CheckBox'.
Please help me.
I'll appreciate your help.
Thanks, Rob
I am very new to ASP.Net 2, and stuck with a problem.
How can I execute a client side JavaScript function on CheckBox click.
I am able to execute function at server, But I don't know how to validate at
client side before going to server.
This code is within a GridView
<ItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server"
Checked='<%# Bind("OpenConnection") %> '
Enabled="True"
OnCheckedChanged="OpenConnection_Clicked" AutoPostBack="True" />
</ItemTemplate>
When I put onClick="Javascript:FunctionName" within the tag, it says:
Validation (ASP.Net): Attribute'onclick' is not a valid attribute for
element 'CheckBox'.
Please help me.
I'll appreciate your help.
Thanks, Rob