Ok, here I've a question to ask my fellow techjamaicans. With .Net all grown up, we find it boasting about a lot of features of which Master Files is one.
Now I must say design with master files can make development cool, but to be honest I was a bit apprehensive when I first read about it way back when.
Any way I have a situation to which I need alternate solutions...Since most of my site pages use a master page I decided to put the session checks there rather than having to include these checks on all the pages. From the jump this sounds like a good idea, however I found myself in a bind. Due to the fact that the page_load event of the content page is fired before that of the master page...some of my code is started to break.
Case in point. Say a user logs on to my system...some session variables are created.
Now, most pages use one of a number of session variables in their respective load event, for instance to...pull some user specific stuff from the db...Now if it so happens that the session times out...the content page load event will still try to do what its supposed to do...but oops no session variable...the situation only gets handled after, within the master page's load event...bummmer. I know it could solved by making redundant checks in each content page...but that would in essence be sucky...what ideas do you guys have.