VB to C#, need help with WithEvents

  • Thread starter Thread starter Tee
  • Start date Start date
T

Tee

Hi,

I am converting a code from VB to C#.

in VB, it's
Private WithEvents MyButton As Button

what's the code in C# ?

I can't get the replacement for the "WithEvents" in C#.

Anyone know it?



Thanks.
 
Tee said:
Hi,

I am converting a code from VB to C#.

in VB, it's
Private WithEvents MyButton As Button

what's the code in C# ?

I can't get the replacement for the "WithEvents" in C#.

Anyone know it?

Simple: there isn't one.
 
What he means is that you don't need an equivalent - C# is smart
enough to know what you mean once you make the declaration (ditto
for "Shadows", "Overloads", etc.).

*-----------------------*
Posted at:
www.GroupSrv.com
*-----------------------*
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Assigning event handlers to another object 2
VB to C# 5
C# Equivalent to VB's WithEvents? 2
WithEvents 6
COM Object Events 2
How to do "WithEvents" in C#? 11
WithEvents in C#.NET 4
C# Equivalent of WithEvents? 5

Back
Top