protected void ButtonSheel_Click(object sender, EventArgs e)
+3
A:
The mark up is used (at runtime) to define a class which inherits from the class defined in your code behind (you can see this in the @Page
declaration where we define what class the page inherits from)
<%@ Page Inherits="_Default" ...
This class needs access to the methods that you define to be the event handlers for your controls (button clicks etc...), and so these methods they need to be marked as at least protected (rather than private) to allow the inheriting markup class access.
Kragen
2010-09-24 06:51:56