Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

asp:Checkbox in TemplateColumn OnCheckedChanged not get called

Status
Not open for further replies.

harmmeijer

Programmer
Mar 1, 2001
869
CN
I have an asp:checkbox in a templatecolumn but no matter how many times I check and uncheck the box the OnCheckedChanged never gets called.
yes it is runat="server"
here is some code of the aspx file:
Code:
<asp:TemplateColumn HeaderText="Register">
	<ItemTemplate >
		<asp:CheckBox
			runat="server"
			id="chkDoCourse"
			AutoPostBack="True"
	OnCheckedChanged="registerUnregister" />
	</ItemTemplate>
</asp:TemplateColumn>


here is the .vb file:
Code:
    Protected Friend Sub registerUnregister(ByVal sender As Object, ByVal e As System.EventArgs)
        Dim i As Int32 = 22
        Dim s As String = "this code never gets called no matter how many times i tick and untick the checkbox"
    End Sub

Anobyody got an idea what's going on here?



Greetings, Harm Meijer
 
Solved it (I think), page.databind gets called every page load.




Greetings, Harm Meijer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top