MultiviewControl unable to display
I have a menu with several buttons.
When i press the first button it sets the view to "visible". Then a textbox + a button appear wihout any problem.
The problems lies where i wanne开发者_如何学JAVA do the exact same thing for another button, the controls actually never show up. Both are in 2 seperate views within 1 multiview control.
The multiview is located in a content page, and everything is triggered by pressing on a button that is located in the MasterPage. In that button click event is a Response.Redirect that sends the page to the content page.
string a = Request.QueryString["a"];
string b = Request.QueryString["b"];
if (a != "")
{
if (a == "addA")
{
MultiviewQuestions.SetActiveView(viewAddA);
}
}
if (b != "")
{
if (b == "addB")
{
MultiviewQuestions.SetActiveView(viewAddB);
}
}
This sets up a condition to have 2 active views which isn't allowed. Last in will always win. You need to specify which one you are setting if both a and b are set and true.
精彩评论