In my application, I want the program to redirect the user to a new page AND slide open the list of SUBITEMS when a panelBar ITEM is clicked/selected. However, I am unsure as how this should be implemented.
I have used ".Action" along with "item" of my panelBar but this is unfortunately throwing an error. A small portion of the code is displayed below for your convenience (mainly focus on the second last line). The error being thrown is:
HttpException was unhandled by user code
<% Html.Telerik().PanelBar()
.Name("PanelBar")
.SelectedIndex(0)
.Items(item =>
{
item.Add()
.Text("Home").Action("Index", "Home")
.Items(subItem =>
{
subItem.Add().Text("My Profile").Action("MyProfile", "Profile");
subItem.Add().Text("Test");
});
item.Add()
.Text("Orientation").Action("Index", "Orientation")
.Items(subItem =>
{
subItem.Add().Text("GridView");
subItem.Add().Text("Scheduler");
subItem.Add().Text("Docking");
subItem.Add().Text("Chart");
});
}).Render();
%>
It seems like ".Action" is not working in this case. So my question is, how should I make the item take in an event?