A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Flash Scoll bar

  1. #1
    Junior Member
    Join Date
    Apr 2001
    Posts
    1

    Smile

    I need some help on ......
    creating a flash scoll bar ....
    can some body help me on it , or tell me where can I get more info about it ..! Thanks for the kindness ...

  2. #2
    Member
    Join Date
    Mar 2001
    Posts
    32

    Good Luck!

    What I do here is caculate the distance to make the perfect scrollbar. The only thing you need to do, is piece it all together, hehe.

    Set Variable: "BarRange" = (GetProperty ( "DownButton",_y ) - GetProperty ( "UpButton",_y )) - 20
    Set Variable: "Value" = MinValue
    Set Variable: "PreviousValue" = Value

    Set Property ("DragButton", Y Position) = (((Value - MinValue) / (MaxValue - MinValue)) * BarRange) + 10
    Call ("../:ScrollChange")

    Set Variable: "Value" = (Int (((Value - MinValue) + (Increment / 2)) / Increment) * Increment) + MinValue

    If (not (../:Step = 0))
    If (not ((../:Value + ../:Step) < ../:MinValue) and not (../:MaxValue < (../:Value + ../:Step)))
    Set Variable: "../:Value" = ../:Value + ../:Step
    Call ("../:SetPosition")
    End If
    Else
    If (../ragging = 1)
    Set Variable: "../:Value" = (((GetProperty ( "../DragButton",_y ) - 10) / ../:BarRange) * (../:MaxValue - ../:MinValue)) + ../:MinValue
    Call ("../:RoundValue")
    Call ("../:SetPosition")
    End If
    End If

    On (Press)
    Set Variable: "../:Step" = - ../:Increment
    End On
    On (Release, Release Outside)
    Set Variable: "../:Step" = 0
    End On

    On (Press)
    Set Variable: "../:Step" = ../:Increment
    End On
    On (Release, Release Outside)
    Set Variable: "../:Step" = 0
    End On

    On (Press)
    Set Variable: "Dragging" = 1
    Start Drag ("DragButton", L=0, T=10, R=0, B=(BarRange + 10), lockcenter)
    End On
    On (Release, Release Outside)
    Set Variable: "Dragging" = 0
    Stop Drag
    End On

  3. #3
    Moderator
    Join Date
    May 2000
    Posts
    793
    try doing a search for "scroller" in the movies section, you'll find loads of fla's to help you out.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center