How to pass variable from master page to contents page on postback?

Hi All,
My master page has a dropdown box with a submit button.
When user clicks the button I need to send selecteditem's value  to the contents page's page_load event.

Can someone please give me the *** code ***, preferably in C#.

Much appreciated.

Who is Participating?
samtran0331Connect With a Mentor Commented:
Yes, properties (variables, controls, events) made public can be read between a master/content page.
This is a nice, short article on it:
To send the parameters:
Response.Redirect("StaffProfile.aspx?StaffID=" + parameter.ToString());

StaffProfile is the page you want to redirected to.
Parameter is the one you want to pass

To get the Parameters:

 parameter= int.Parse(Request.Params.Get("StaffID").ToString());

you don't need to use Int, the data type can be different
ctncommsAuthor Commented:
Hi Scorpiia,
I can not use querystring or cookies or sessions.

Thanks for your time.

Any other approach? like using properties? or whatever?

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.