(I searched the forum, couldn’t find anything..)

Should Page Loaded events on a Master be executed?

My view is, any page that is loaded should have it’s Page Loaded event executed, and that includes the Master Page, each and every time, even if switching between pages with the same master.

Or you could argue you have a Master, and you only want the Page Loaded to be executed once if you jump between pages with the same master.

But in this particular case, the Page Loaded event is not being triggered at all on the Master.

5 answers

Hi Tim, when a page is working as a master page, it just provides its content to its adopter and does not work like a normal page. So there is only one page loaded at a time in the simulation. When you switch to another page, only one “Page Loaded” event will be triggered.

Why ForeUI allows user to handle “Page Loaded” event for master page? It is because the master page can be used as normal page as well. A good example is to simulate the popup window scenario: the background content is a normal page before the popup window shows up.

Actually there is a work arround to make it work as you expected: you can create a custom event in the master page and trigger the custom event in the “Page Loaded” event handler for any page you like.


Hi Xavier, the Custom Event in the Master Page is how I have it now, but I wanted to avoid putting a Page Loaded in each page that does the same thing, as I have about 8+ pages using the same Master.

Please consider a mechanism that allows Page Loaded event to work for Master Pages i.e. Master Page Loaded event perhaps? That only fires when the page displayed is using the Master Page – does that make sense?

That would be lovely!

In this scenario, the user must be ‘logged in’ (simulated via a Global Property), and if they go to a page and they are not logged in, it jumps to the Sign In page. Really just another time saver..


Hi Tim, I understand your concern. It seems to be a good idea to have a new event for master page. Maybe rename the event to “Loaded as Master Page” is better.


Perfect – as long as it fires each time that would do the job nicely.


“Loaded as Master Page” event is available from V2.72.


This question is now closed