Rank: Advanced Member Groups: Member
Joined: 10/31/2007 Posts: 51
|
Hi
can I cancel a tabstrip item selection server side. If so how?
I have a tabstrip linked to a multipage with a pageview for each tab item.
For each page view I dynamically load a usercontrol tab selection.
e.g
Tabstrip MultipPage pageview2 = mycontrol1 pageview2 = mycontrol2
I would like to peform an evaluation each time a tab item is selected and if required cancel the tab selection.
Is this possible?
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,217
|
Hi,
You won't be able to "cancel" it on the server side since the post back has already occurred. You can just perform your validation and then put the TabStrip into it's previous tab by setting the TabStrip's SelectedIndex, for example:
TabStrip1.SelectedIndex = 0
Put the TabStrip back to the first tab regardless. You will need to have your own mechanism to maintain the previous selected tab, though. One possible solution is to store it in ViewState.
Thanks
|