Object events

  • Thread starter Thread starter SimonZ
  • Start date Start date
S

SimonZ

In ASP.NET 2.0, C# I can see object events only in design view.

That is very disturbing. I don't use design view at all. I work with source
view and code behind.

If you change language to VB.NET that you can see events also in code
behind.

In asp.net 1.1 that works.

Any idea?

regards,S
 
if your talking about what I think ur talking, the way I do it is pretty
easy. First, I disable AutoWireUp. Then I override OnInit and I hook up my
events in there like it was in 1.1

protected override void OnInit(EventArgs e)
{
Send.Click += new EventHandler(Send_Click);
base.OnInit(e);
}


i actually changed the templates used in vs.net 2005, you can find them all:
C:\Program Files\Microsoft Visual Studio
8\Common7\IDE\ItemTemplates\Web\CSharp\1033 and modify them. i had some
problems with the cache of those, located
C:\Program Files\Microsoft Visual Studio
8\Common7\IDE\ItemTemplatesCache\Web\CSharp\1033
but it eventually all worked out,not quite sure how to be honest :)

Karl
 
Thank you Karl,

it's not what I mean.

In VS2003 you had 2 combo boxes on top: first one with objects and second
one with events.

When you selected the object from first combo box, the second combo box was
filled with the events of this object.

When you selected the some event from second combo box, the wrapper for this
event was automaticly added to your code.

Now in VS2005 it still works but only if you have VB as your language.

In C# that is gone. I don't know why?

Auto wire up is also something to think about. Maybe I'll try your way, but
it doesn't bother me a lot.

Thanks,
Simon



"Karl Seguin [MVP]" <karl REMOVE @ REMOVE openmymind REMOVEMETOO . ANDME
net> wrote in message news:%[email protected]...
 
Back
Top