![]() |
Event handlers
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 |
Re: Event handlers
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" <IHateSpam@sapm123.com> 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 > |
Re: Event handlers
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" <IHateSpam@sapm123.com> wrote in message news:eoDLmDGLEHA.2100@TK2MSFTNGP10.phx.gbl... > 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 > > |
| All times are GMT. The time now is 07:27 PM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.