Page view counter

How Do I: Handle Events in Master and Content Pages

In this video Chris Pels will show how events are handled in master and individual content pages. Even though the end result of a master and individual content page is a single ASP.NET page rendered in the user's browser the event handling in each type of page is handled separately. If a control is located in the master page the corresponding event handler is located in the master page by default. The same is true for controls in the content page. See two approaches to having the events for a control located in the master page handled in the code behind of the content page. This allows “communication” between the master page and content page.

Presented by Chris Pels

Duration: 23 minutes, 26 seconds

Date: 21 February 2008

Watch the video   |   Download the video   |   Get VB code  or  C# code

Video downloads: WMV | Zune | iPod | PSP | MPEG-4 | 3GP

Audio downloads: AAC | WMA | MPEG-4 | MPEG-3 | MPEG-2

Comments : 5

Leave a Comment

sappidireddy : On April 23, 2008 10:39 AM said:

Hi Chirs Pels,

I am  trying to access master page Menu MenuItemDataBound event in the content page. But I am getting compilation errors.

My first Error is

Public property in the master page does not exist in content page.

Second error is:

Eventhandler can't be over loaded.

new EventHandler(ContentList_SelectedIndexChanged);

In general event hander will take two parameter But here you are passing only one parameter.

Is there any different way we can acheive.

One more thing I want suggest can you do some viedos on Gridview, details view and form view. More on Dataconrols.

Thaks,

Venkat

cv_vikram : On August 09, 2008 8:35 AM said:

thanks....

smcmiata : On September 22, 2008 6:18 PM said:

Works great, except how can I get the value of the selected radio button?

djibril_chimere_DIAW : On October 29, 2008 12:10 PM said:

Thanks! Jërëjëf!

djafer : On November 11, 2008 2:12 PM said:

Teşekkürler, güzel çalışma.

Leave a Comment

You must be logged in to leave a comment. Click here to log in.

Microsoft Communities