Newbie Question - Intellisense with this.OnLoad event

  • Thread starter Thread starter Damien Sawyer
  • Start date Start date
D

Damien Sawyer

Hello all,

I'm in the process of transfering from VB to C# and am having a bit of
trouble getting the hang of the intellisense.

I wish to add events to my form - in this case, the onLoad event. I've
been in the habbit of typing object.event+=.... The intellisense then
kicks in and, as you'd all know, builds the method signatures for me
when I press [tab].

However, this doesn't seem to work with the form events - ie
this.OnLoad+= does nothing.

Can someone please help?

Thanks in advance,


Damien Sawyer
 
Damien said:
Hello all,

I'm in the process of transfering from VB to C# and am having a bit of
trouble getting the hang of the intellisense.

I wish to add events to my form - in this case, the onLoad event. I've
been in the habbit of typing object.event+=.... The intellisense then
kicks in and, as you'd all know, builds the method signatures for me
when I press [tab].

However, this doesn't seem to work with the form events - ie
this.OnLoad+= does nothing.

Can someone please help?

Thanks in advance,


Damien Sawyer

This works the same way in C#. Perhaps the object you are trying to add
the event to doesn't support it.

John
 
Hi John,

Sorry - maybe I didn't make myself clear. That += code 'was' for C#.

form most definate does support the onLoad event - it's a primary event.

My question is, how do I automatically generate a method for it.


Thanks again in advance



DS
 
Damien said:
Hi John,

Sorry - maybe I didn't make myself clear. That += code 'was' for C#.

form most definate does support the onLoad event - it's a primary event.

My question is, how do I automatically generate a method for it.


Thanks again in advance



DS

I'm sorry, I should have read your post a little more closely. It
should be

this.Load +=

not

this.OnLoad +=

John
 
Back
Top