Results 1 to 2 of 2

Thread: Button To Move To Next Frame

  1. #1
    Join Date
    Jul 2008
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Button To Move To Next Frame

    Hi

    I am quite new 2 the world of flash. I would appreciate receipt of an appropriate piece of code to be used for a button which shall play a clip only for the time till the same is kept pressed.

    For example I have a map to be zoomed to the desired size till I keep the button pressed and stop on release.

    Thanx in advance.

  2. #2
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    AS 2.0
    Code:
    button.onPress = function() {
    	this.onEnterFrame = function() {
    		this.nextFrame();
    	}
    }
    
    button.onRelease = function() {
    	delete this.onEnterFrame;
    }
    Do you need 3.0?

Bookmarks

Posting Permissions

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