Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Overriding and methods
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00951733
Message ID:
00951780
Vues:
8
Each panel on the form is an instance of a panel. You cannot override a method on an instance. You can create three subclasses outside of your form but that is probably not what you want to do in this case. Instead you should look for some event on each instance to handle. If there is no suitable event you can create your own on the panel base class and raise it at the appropriate time.

panel1.Event += new EventHandler(eventhandler1);
panel2.Event += new EventHandler(eventhandler2);
panel3.Event += new EventHandler(eventhandler3);


>I have three panels on one form.
>
>Each panel will have code unique to it.
>
>How do I override each panels MyPreDisplay() i though i could do a public override and all would be fine, but i guess that is not the case.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform