Ok, my masterpage has a dropdown which controls size which affects a lot of things. I need to access the dropdown index from content pages so I do it using this code.
public partial class MasterPage : System.Web.UI.MasterPage
{
public DropDownList MySize { get { return _ddlSize; } }
}
I am using Ajax and when the size changes the menu on the Masterpage changes just fine.
But when I click on the updated menu it uses the zero index of the dropdown list on my contentpage even through visually it shows the size I selected.
int size = Convert.ToInt32(Master.MySize.SelectedItem.Text); //Uses 0 index :(
I don't want to use Session, I just don't get why this doesn't work 100% of the time. Anyone have any ideas?