CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Nov 2006
    Posts
    357

    Quick way of assigning events in designer?

    Hey,

    On thing that really bugs me about VS (which is probably down to my lack of knowledge) is that whenever i want something to do anything other than its default event (like forms do OnLoad, buttons do OnClick etc) i have to manually write the code for it...

    Is there any way to get the designer to create simple events for me, so like giving a form OnClick event?

  2. #2
    Join Date
    Jul 2007
    Location
    Illinois
    Posts
    517

    Re: Quick way of assigning events in designer?

    Not to my knowledge, however if you look at the Properties pane for the control you want to handle events for there is a lightning bolt at the top. Click that and it will show you all events that are available to handle and all you have to do is double click the event and it will generate a handler for you.
    R.I.P. 3.5" Floppy Drives
    "I know not with what weapons World War III will be fought, but World War IV will be fought with sticks and stones." - Albert Einstein

  3. #3
    Join Date
    Nov 2002
    Location
    .NET 3.5 VS2008
    Posts
    1,039

    Re: Quick way of assigning events in designer?

    Quote Originally Posted by RaleTheBlade View Post
    Not to my knowledge, however if you look at the Properties pane for the control you want to handle events for there is a lightning bolt at the top. Click that and it will show you all events that are available to handle and all you have to do is double click the event and it will generate a handler for you.
    Well...it can't get much simpler than that really...

  4. #4
    Join Date
    Nov 2006
    Posts
    357

    Re: Quick way of assigning events in designer?

    Thats the boy! thanks for that... never knew it was there and ive been using VS for years

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured