Monday, March 26, 2012

Updating MasterPage panel from content page

Hello,

I have created a shopping cart which users can add products to within an update panel in a content page. However in the masterpage there is a 'basket' that displays how many products are currently in the basket. I need to find a way of updating this basket whenever the updatepanel in the content page is reloaded. Is this possible.

Thanks,

Curt.

Yes, create a Public Property on your Master Page and set the baskek based on this value. The value can then be updated from your content page (you can get access to the Master Page via Page.Master).


Thank you for your reply.

Could you give me some more help on how to do this as I don't have much experience with Public Properties just yet?

Thanks.


Here's a sample Public Property with a type of String:

Public Property Name()As String Get Return _NameEnd Get Set(ByVal valueAs String) _Name = valueEnd Set End Property

No comments:

Post a Comment