Calling event handler using Master Pages

Discussion in 'ASP .Net' started by H F, Mar 25, 2008.

  1. H F

    H F Guest

    Hi all

    I created a user control that has a button and have added it to the
    Master page. When I click on the button, the onClick event handler in
    the user control is not fired. How do I reference the onClick event
    handler?

    thanks
    Harry
    H F, Mar 25, 2008
    #1
    1. Advertising

  2. H F

    Masudur Guest

    On Mar 25, 11:31 pm, H F <> wrote:
    > Hi all
    >
    > I created a user control that has a button and have added it to the
    > Master page. When I click on the button, the onClick event handler in
    > the user control is not fired. How do I reference the onClick event
    > handler?
    >
    > thanks
    > Harry


    Hi...

    If you create event handler for the button in usercontrol's codebehind
    file it is suppose to fire. if you want to handler the event in master
    page's codebehind do create a public event in user control raise the
    event in usercontrol when the button is clicked and subscribe the
    event in master page's codebehind.

    Thanks
    Masudur
    http://munna.shatkotha.com
    Masudur, Mar 25, 2008
    #2
    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. Doug McCann
    Replies:
    1
    Views:
    1,001
    William Brogden
    Aug 5, 2004
  2. Replies:
    1
    Views:
    3,198
    PeterKellner
    May 16, 2006
  3. =?Utf-8?B?RG9u?=

    Using Master Pages and Base Pages

    =?Utf-8?B?RG9u?=, Sep 12, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    335
    S. Justin Gengo
    Sep 12, 2006
  4. Replies:
    1
    Views:
    694
    Damien
    Feb 22, 2007
  5. katmagic
    Replies:
    0
    Views:
    1,246
    katmagic
    Dec 26, 2008
Loading...

Share This Page