The OnCheckedChanged event of ASP.Net RadioButton control provides the functionality to handle the post back click event of multiple radiobutton controls individually. The CheckedChanged event occurs only if the AutoPostBack property of radiobutton control is specified with "true" value. In the previous sample we discussed about the feature of AutoPostBack property that allows the radiobutton control to automatically post back the web page to the server. We also used the Page Load method of the ASP.Net web page to read and display the value of checked property of radiobutton controls. But all that will become more complex when there will be a number of radiobutton controls on a single web page. It will be difficult to handle the post back event of each radiobutton control at page load. That's why ASP.Net RadioButton control includes the OnCheckedChanged that enables you to handle the post back click event of the radiobutton controls directly and individually.
The difference between the previous sample and this sample is that in the previous sample it executes the C# code to read and display the checked state of radiobutton control each time where as in this tutorial we have used the OnCheckedChanged event that occurs only if the user clicks the radiobutton control to change its checked state.
Try the sample below to understand the functionality of OnCheckedChanged event of ASP.Net RadioButton control: