views:

1479

answers:

1

Is there any way I can find what the previous active was when the active tab changed event is fired?

A: 

OK I've found a very simple solution.

JavaScript:

<script type="text/javascript">
    var lasttab = 0;
    function tabChanged(sender, args) {
        // do what ever i want with lastTab value
        lasttab = sender.get_activeTabIndex();
    }
</script>

Asp.net

    <cc1:TabContainer ID="TabContainer1"  
         runat="server" ActiveTabIndex="0" OnClientActiveTabChanged="tabChanged">
John Nolan