3 Replies Latest reply on Aug 19, 2009 10:35 PM by Flex harUI

    Tab navigation

    Rajesh Subbiah Level 1

      How to disable the default tab navigation .

      I need to load the tab manually through the click event.

      Please suggest me ,how to proceed with this issue.

        • 1. Re: Tab navigation
          Gregory Lafrance Level 6

          If you mean changing the default tab order in an application:

           

          http://livedocs.adobe.com/flex/3/html/help.html?content=accessible_6.html

           

          If this post answers your question or helps, please mark it as such.

          • 2. Re: Tab navigation
            Rajesh Subbiah Level 1

            Hi

             

            I want to abort the tab change

            for example

             

            If there is any error in the first tab

            if the user clicks second tab the navigation should go to second tab. it must remain in the first itself...

            Please suggest which event to handle

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

             

            <?xml version="1.0"?>

            <!-- containers\navigators\TNSimple.mxml -->

            <mx:Application

             

             

            xmlns:mx="http://www.adobe.com/2006/mxml"

            >

            <mx:Script>

            <![CDATA[

             

             

            import

            mx.events.IndexChangedEvent;

             

             

            import

            mx.controls.Alert;

             

             

            public function

            onTabIndexChange(event:MouseEvent)

            {

             

            sample.selectedIndex = 0;

            sample.setChildIndex(sample.getChildAt(0),0);

            Alert.show(

             

            "testing","test"

            );

            }

            ]]>

            </mx:Script>

             

             

             

            <mx:TabNavigator id="sample" borderStyle="solid

            "

            initialize="sample.addEventListener(MouseEvent.MOUSE_DOWN,onTabIndexChange,

             

            true)"

            >

             

             

             

            <mx:VBox label="Accounts

            "

            width="

             

            300

            "

            height="

             

            150"

            >

             

             

            <!-- Accounts view goes here. -->

             

             

            </mx:VBox>

             

             

             

            <mx:VBox label="Stocks

            "

            width="

             

            300

            "

            height="

             

            150"

            >

             

             

            <!-- Stocks view goes here. -->

             

             

            </mx:VBox>

             

             

             

            <mx:VBox label="Futures

            "

            width="

             

            300

            "

            height="

             

            150"

            >

             

             

            <!-- Futures view goes here. -->

             

             

            </mx:VBox>

             

             

             

            </mx:TabNavigator>

             

             

             

             

            • 3. Re: Tab navigation
              Flex harUI Adobe Employee

              Get the KEY_FOCUS_CHANGE event and call preventDefault()

               

              Alex Harui

              Flex SDK Developer

              Adobe Systems Inc.

              Blog: http://blogs.adobe.com/aharui