I've been looking for a solution to this for several hours now and cannot find a solution.
The Scenario:
master1 has code something like:
Protected Sub Usr1_ButtonClicked(ByVal sender As Object, ByVal e As System.EventArgs) Handles Usr1.ButtonClicked RaiseEvent HandleClickEvent(sender, e) End Sub
when thePage loads I see it register the handler on master1
I think I'm doing something stupid. I would appreciate some help.
Thanks!
Does the event on your master page class need to be an actual event handler? You should be able to just make it a public method and access it from your page (or user control) event handler like this:
Page.Master.MyPublicMasterPageMethod()
To call a method on your content page from your master page you could use VB's CallByName method: http://msdn.microsoft.com/en-us/library/22x2chfx.aspx
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.