Create a ScrollBar using and : ScrollBar « Components « Flex

Home
Flex
1.Chart
2.Components
3.Container
4.Data Model
5.Development
6.Effects
7.Event
8.Graphics
9.Grid
10.Style
Flash / Flex / ActionScript
Flash Tutorials
Flex » Components » ScrollBarScreenshots 
Create a ScrollBar using and
Create a ScrollBar using <mx:VScrollbar> and <mx:HScrollBar>
        

<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
    <mx:Script>
        
        import mx.events.ScrollEvent;
        private function myScroll(event:ScrollEvent):void {
            showPosition.text = "Current scroll position: " + event.currentTarget.scrollPosition;
        }
      
    </mx:Script>
    <mx:Label width="100%" color="blue"
        text="Click on the scroll bar to view its properties." />
    <mx:VScrollBar id="bar" height="100%" 
                   minScrollPosition="0"
                   maxScrollPosition="{this.width - 20}" 
                   lineScrollSize="50"
                   pageScrollSize="100" 
                   repeatDelay="1000" 
                   repeatInterval="500"
                   scroll="myScroll(event);" />
    <mx:TextArea id="showPosition" height="100%" width="100%" color="blue" />
</mx:Application>

   
    
    
    
    
    
    
    
  
Related examples in the same category
1.VScrollBar sroll eventVScrollBar sroll event
2.Add the HScrollBar and VScrollBar components to the applicationAdd the HScrollBar and VScrollBar components to the application
3.Set min/max scroll position for ScrollBarSet min/max scroll position for ScrollBar
4.ScrollBar SimpleScrollBar Simple
5.minScrollPosition,maxScrollPosition,lineScrollSize,pageScrollSize,repeatDelay,repeatIntervalminScrollPosition,maxScrollPosition,lineScrollSize,pageScrollSize,repeatDelay,repeatInterval
java2s.com  |  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.