2 Replies Latest reply on Oct 1, 2008 8:54 PM by kittuokkade

    Tabbing TextInput Components does NOT scroll the container

    babo_ya Level 3
      I have a VBox and inside of the VBox I have about 20 TextInput Components and the height of the VBox is only 400 so a scrollBar appears and only 10 shows up and in order to see more I have to scroll down. Well, the issue is when I TAB from 10 th TextInput Component to next TextInput Component VBox doesn NOT automatically scrolls. And my client really hates it!!

      Here is an example. Lanuch it and hit the tab.

      Does any one know how to make the VBox auto scroll when I hit TAB?

      Thanks for your help.
        • 1. Re: Tabbing TextInput Components does NOT scroll the container
          Level 7

          "babo_ya" <webforumsuser@macromedia.com> wrote in message
          news:gc0hbk$8pq$1@forums.macromedia.com...
          >I have a VBox and inside of the VBox I have about 20 TextInput Components
          >and
          > the height of the VBox is only 400 so a scrollBar appears and only 10
          > shows up
          > and in order to see more I have to scroll down. Well, the issue is when I
          > TAB
          > from 10 th TextInput Component to next TextInput Component VBox doesn NOT
          > automatically scrolls. And my client really hates it!!

          Look at verticalScrollPosition.

          HTH;

          Amy


          • 2. Tabbing TextInput Components does NOT scroll the container
            kittuokkade

            hi babo_ya ,
            you can set vertical scroll position programmatically some thing like this can work for you.

            <?xml version="1.0" encoding="utf-8"?>
            <mx:Application xmlns:mx=" http://www.adobe.com/2006/mxml" layout="absolute" >
            <mx:Script>

            <![CDATA[
            import mx.controls.Alert;
            private function setScroll(){
            vBox.verticalScrollPosition+=10;
            }

            ]]>

            </mx:Script>
            <mx:VBox id="vBox" width="300" height="400" verticalGap="20"
            verticalScrollPolicy="auto"

            >
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            <mx:TextInput focusOut="setScroll();"/>
            </mx:VBox>
            </mx:Application>