Event handlers

Discussion in 'ASP .Net' started by A.M, Apr 27, 2004.

  1. A.M

    A.M Guest

    Hi,

    Using C#, ASP.NET 1.1 and VS.NET 2003, I am trying to add Page_Error event
    handler to my page. I know that I can Manually type the handler, but is
    there any way to have IDE add the Page_Error event handler to the page?

    Thanks,
    Allan
    A.M, Apr 27, 2004
    #1
    1. Advertising

  2. A.M

    Scott Allen Guest

    Hi Allan:

    Do you mean for just one page?

    When in design mode, select View -> Properties, then select your page
    in the drop down list of the properties window. Next, click on the
    lightning bolt (event handlers for the page), and double click on
    Error to have the IDE put all the setup code in place for you.

    --
    Scott
    http://www.OdeToCode.com


    On Tue, 27 Apr 2004 10:06:36 -0400, "A.M" <>
    wrote:

    >Hi,
    >
    >Using C#, ASP.NET 1.1 and VS.NET 2003, I am trying to add Page_Error event
    >handler to my page. I know that I can Manually type the handler, but is
    >there any way to have IDE add the Page_Error event handler to the page?
    >
    >Thanks,
    >Allan
    >
    Scott Allen, Apr 27, 2004
    #2
    1. Advertising

  3. Very simple:
    ------------

    1. Open the page in question.
    2. Go to the properties window and find the name of the class for the code
    behind
    For example: default.aspx = _default
    3. Click on the lightning bolt at the top of the Properties window
    4. Add an event name for Error and click enter
    5. This takes you to the new event, so write some code
    6. Save the page

    You now know something very few of the VS.NET devs I know happen to be privy
    to. ;->

    --
    Gregory A. Beamer
    MVP; MCP: +I, SE, SD, DBA

    **********************************************************************
    Think Outside the Box!
    **********************************************************************
    "A.M" <> wrote in message
    news:...
    > Hi,
    >
    > Using C#, ASP.NET 1.1 and VS.NET 2003, I am trying to add Page_Error event
    > handler to my page. I know that I can Manually type the handler, but is
    > there any way to have IDE add the Page_Error event handler to the page?
    >
    > Thanks,
    > Allan
    >
    >
    Cowboy \(Gregory A. Beamer\), Apr 27, 2004
    #3
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Boban Dragojlovic

    Dynamic Buttons and Event Handlers, revisited

    Boban Dragojlovic, Jun 24, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    1,871
    Boban Dragojlovic
    Jun 24, 2003
  2. Trevor Hartman

    Re: crazy event handlers!

    Trevor Hartman, Jun 25, 2003, in forum: ASP .Net
    Replies:
    2
    Views:
    967
  3. Oisin Grehan
    Replies:
    3
    Views:
    486
    Natty Gur
    Jul 15, 2003
  4. Robert Millman

    Debug step into event handlers

    Robert Millman, Jul 29, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    420
    Robert Millman
    Jul 29, 2003
  5. Matt Sogla

    Losing event handlers

    Matt Sogla, Jul 30, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    379
    Alvin Bruney
    Jul 31, 2003
Loading...

Share This Page