Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Button Event Handler scope (private vs public) ?
Message
From
30/08/2005 12:51:18
Eugenio Casal
Futura Tecnologia Informação Consult Ltd
São Paulo, Brazil
 
 
To
30/08/2005 11:38:34
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
C# 1.1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01045181
Message ID:
01045210
Views:
26
Hi Alex,

>Why? Why does it need to be public when it is in the same page? All it does is it runs the code as a PostBack AFAIK.
>I fail to see why the auto-created private signature does not work.

This happens because the ASPX Page is based in the class declared in the aspx.cs and it does not have access to the private members.

You could have used protected instead of public if you prefer.

Regards,

Eugênio
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform