473,811 Members | 2,770 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Master page event

I have button on master page.

How can I reference the button clik event from content page?

Thanks,S
Dec 21 '05 #1
3 1271
Build an event from your matser page (it's just like a user control). Then
have the master page handle its own button event and in that event handler
raise the master's custom event. You simply have the page register for the
master's custom event. Check out the <%@ MasterType %> directive on your
ASPX to get strongly typed access so you can register for the event.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have button on master page.

How can I reference the button clik event from content page?

Thanks,S

Dec 21 '05 #2
Thank you brock.

Do you have some example?

Regards,S
"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:b8******** *************** ***@msnews.micr osoft.com...
Build an event from your matser page (it's just like a user control). Then
have the master page handle its own button event and in that event handler
raise the master's custom event. You simply have the page register for the
master's custom event. Check out the <%@ MasterType %> directive on your
ASPX to get strongly typed access so you can register for the event.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have button on master page.

How can I reference the button clik event from content page?

Thanks,S


Dec 21 '05 #3
Not really, but have you checked out the quickstarts:

http://66.129.71.130/QuickStartv20/a...s/default.aspx

It will get you started. And so from the page's OnInit just do a += to register
for the event from the master.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Thank you brock.

Do you have some example?

Regards,S
"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:b8******** *************** ***@msnews.micr osoft.com...
Build an event from your matser page (it's just like a user control).
Then have the master page handle its own button event and in that
event handler raise the master's custom event. You simply have the
page register for the master's custom event. Check out the <%@
MasterType %> directive on your ASPX to get strongly typed access so
you can register for the event.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have button on master page.

How can I reference the button clik event from content page?

Thanks,S

Dec 21 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
1969
by: Martijn Saly | last post by:
Hi there, I've created a master page with some controls on it, a Calendar control among others. Now depending on the date(s) selected, the content page needs to be updated. In the masterpage I've created StartDate and EndDate properties, which are basically wrappers around the SelectedDates property from the Calendar control. When I select another date in the Calendar, the page updates normally, but when Page_Load for the content page...
14
2409
by: multiformity | last post by:
So I have been working on an opensource project for a while, and decided to really try to make it look better after focusing on the functionality most of this time. Up to now, I have simply used a standard ASPX page with minor modifications to it. All of my pages inherit from a "BasePage.cs" class, that handles common things like getting the user's information out of the session, determines if a page should or should not be password...
5
2570
by: Federico | last post by:
I have a problem, I have an event declared in a Master Page, and I want to use in a Content Page holder of a Content Page. When I want to create the method to handle the event, I can njot reference the Master Page event, in its place IntelliSense shows me a Delegate Sub EventHandler. I am new with events managements, so any help and guiadance will be appreciated. Federico
13
6237
by: Michael | last post by:
I have setup a public variable in the Master Page "code-behind-file". Now I would like to set that value from the UserControl, but I can't seem to find a way to do this. Does anyone have any ideas? I'm basically trying to set it up so that I can keep the User infor (userid, ect) in the Masterpage so that other pages can access it. Thanks for any ideas. Michael
3
1641
by: Brian | last post by:
Master pages run Page_Load() from the deepest level of nesting outwards. So if I write a content page based on a nested master which is then based on some other master, the Page_Loads are executed backwards: Content page, SubMaster Page, Master Page. Does this seem messed up to anyone else?? I can't see any logic in this. But from what I understand, the whole master page scheme is cooked on top of the usercontrol class. So the...
0
2119
by: Managed Code | last post by:
Hello All, Here is my issue and thanks in advance for any assistance. I have a base page with a dropdownlist that fires an event with the selected index. The content page catches the event and sets a connection string to the database. The content page has a simple gridview that should show records from the selected database. Initial content page displays data from correct place. first change of dropdownlist correctly updates content...
0
1659
by: =?Utf-8?B?TWFyayBHaWxrZXM=?= | last post by:
I have designed and written a custom menu like server control. The control inherits from DataBoundControl and implements INamingContainer and IPostBackEventHandler interfaces. The control uses only html mark-up as it’s UI, i.e. tables, table rows and table cells, and no intrinsic html controls such as input or select. The control does not implement any client-side script and therefore redraws its updated UI on postback through the...
7
1373
by: =?Utf-8?B?TWFyaw==?= | last post by:
keywords: asp.net master page rubbish I have written a custom control. The control is a simple html Tab menu control. The control inherits from DataBoundControl and implements INamingContainer, IPostBackEventHanlder and IPostBackDataHandler. The control is engineered to use a hidden client-side input textbox which stores a selected index variable to enable the IPostBackDataHandler to determine a change in tab and trigger a redraw of...
6
9173
by: =?Utf-8?B?SmF5IFBvbmR5?= | last post by:
I am trying to access a Public property on a Master Page from a Base Page. On the content pages I have the MasterType Directive set up as follows: <%@ MasterType virtualpath="~/Master.master" %> On the Master Page I have a public property exposed: Public Property ErrorMessage() As String Get Return txtError.InnerText End Get
0
9731
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9605
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10651
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10136
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7671
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6893
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4342
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3871
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3020
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.