Add control to all pages through Global.asax

  • Thread starter Thread starter Grant Merwitz
  • Start date Start date
G

Grant Merwitz

Hi

Is there a way to add a control to my page through the Global.asax

I would like to place this code in the Session_Start page so its only added
to the first page the user visits.

TIA
 
Create a base page class, that checks for IsNewSession, and adds the
control.

Then have all your pages inherit from this base page.
 
Thanks, that I have used many times before.
But this particular project was not built with that in mind (not built by me
either)
and there are way too many pages to make those changes

Any other ideas?
 
I don't think you can do it from Session_Start. It's way too early.

All you would have to do, is change what all the pages inherit from. That's
not so much.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top