Apply bounce to multiple movieclips

Hello there,
I'm having a bit of a problem with a basic game I'm making where I want to have a number of animals which bounce around the stage.. I can't seem to get the code to apply to more than one of my movieclips using a loop.. if I try to apply vx and vy to the individual movieclips then nothing happens.. for now I have the ten movieclips on the stage but only one whichbounces around.. I have managed to get all of them to move but they each stay in their own area of the stage, but I'd like each to bounce around the stage and not interfere which the others movement..
Thanks in advance
        public function Bounce()
            crosshairs = new Target();
            addChild(crosshairs);
            init();
        private function init():void
            stage.scaleMode = StageScaleMode.NO_SCALE;
            stage.align=StageAlign.TOP_LEFT;
            for(var i = 0; i < 10; i++) {
                horse = new Horse();
                horse.x = Math.random() * stage.stageWidth;
                horse.y = Math.random() * stage.stageHeight;
                addChild(horse);
                animals.push(horse);
                horse.addEventListener(MouseEvent.CLICK, onHorseClick);
            vx = Math.random() * 40 - 20;
            vy = 10;
            addEventListener(Event.ENTER_FRAME, onEnterFrame);
        private function onEnterFrame(event:Event):void
                crosshairs.x = stage.mouseX;
                crosshairs.y = stage.mouseY;
                vy += gravity;
                horse.x += vx;
                horse.y += vy;
                var left:Number = 0;
                var right:Number = stage.stageWidth;
                var top:Number = 0;
                var bottom:Number = stage.stageHeight;
                if(horse.x + horse.width > right)
                    horse.x = right - horse.width;
                    vx *= bounce;
                else if(horse.x - horse.width < left)
                    horse.x = left + horse.width;
                    vx *= bounce;
                if(horse.y + horse.height > bottom)
                    horse.y = bottom - horse.height;
                    vy *= bounce;
                else if(horse.y - horse.height < top)
                    horse.y = top + horse.height;
                    vy *= bounce;
        private function onHorseClick(event:MouseEvent):void {
            var animal = event.currentTarget;
            removeChild(animal);

I've slightly changed the code and I think I can see a little better now what is happening with multiple item..
I created a function which I call onEnterFrame, which loops through an array of movieclips and adds the bounce..
The problem is that when ANY of the movieclips hit ANY of the boundaries, ALL of the movieclips react accordingly instead of just the movieclip which has collided with the side of the stage.
Here is my updated code, can anyone see an answer to this ?
private function onEnterFrame(event:Event):void {
     startBounce();
private function startBounce():void {
     for(var i:uint = 0; i < animals.length; i ++) {
          var animal = animals[i];
          animal.vy += gravity;
          animal.x += vx;
          animal.y += vy;
          if(animal.x + animal.width > right) {
               animal.x = right - animal.width;
               vx *= bounce;
          else if(animal.x - animal.width < left) {
               animal.x = left + animal.width;
               vx *= bounce;
          if(animal.y + animal.height > bottom) {
               animal.y = bottom - animal.height;
               vy *= bounce;
          else if(animal.y - animal.height < top) {
               animal.y = top + animal.height;
               vy *= bounce;

Similar Messages

  • Scroll Bar Controlling multiple movieclips?

    Instead of a scroll bar just controlling one movieclip..How could we get it to control multiple movieclips?
    public class MainScroll extends Sprite
              //private var mc_content:Sprite;
              private var content_mc:MovieClip;
              private var content2_mc:MovieClip;
              private var _scrollBar:FullScreenScrollBar;
              //============================================================================================================================
              public function MainScroll()
              //============================================================================================================================
                   addEventListener(Event.ADDED_TO_STAGE, onAddedToStage, false, 0, true);
              //============================================================================================================================
              private function init():void
              //============================================================================================================================
                   SWFWheel.initialize(stage);
                   //_copy = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque quam leo semper non sollicitudin in eleifend sit amet diam. "; 
                   content_mc = new mc_content();
                   content2_mc = new mc_content2();
                   content_mc.x = 110;
                   content_mc.y = 29;
                   content2_mc.x = 10
                   content2_mc.y = 29
                   addChild(content_mc);
                   addChild(content2_mc);
                   // Scrollbar code 
                   // Arguments: Content to scroll, track color, grabber color, grabber press color, grip color, track thickness, grabber thickness, ease amount, whether grabber is "shiny"
                   _scrollBar = new FullScreenScrollBar(content_mc, 0x000000, 0x408740, 0x73C35B, 0xffffff, 15, 15, 4, true);
                   addChild(_scrollBar);
              //============================================================================================================================
              private function onAddedToStage(e:Event):void
              //============================================================================================================================
                   init();
                   removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage);

    Ok,
    Here is that code:
         import flash.display.*
         import flash.events.*;
         import flash.geom.Rectangle;
         import gs.OverwriteManager;
         import gs.TweenFilterLite;
         public class FullScreenScrollBar extends Sprite
              private var _content:DisplayObjectContainer;
              private var _trackColor:uint;
              private var _grabberColor:uint;
              private var _grabberPressColor:uint;
              private var _gripColor:uint;
              private var _trackThickness:int;
              private var _grabberThickness:int;
              private var _easeAmount:int;
              private var _hasShine:Boolean;
              private var _track:Sprite;
              private var _grabber:Sprite;
              private var _grabberGrip:Sprite;
              private var _grabberArrow1:Sprite;
              private var _grabberArrow2:Sprite;
              private var _tH:Number; // Track height
              private var _cH:Number; // Content height
              private var _scrollValue:Number;
              private var _defaultPosition:Number;
              private var _stageW:Number;
              private var _stageH:Number;
              private var _pressed:Boolean = false;
              //============================================================================================================================
              public function FullScreenScrollBar(c:DisplayObjectContainer, tc:uint, gc:uint, gpc:uint, grip:uint, tt:int, gt:int, ea:int, hs:Boolean)
              //============================================================================================================================
                   _content = c;
                   _trackColor = tc;
                   _grabberColor = gc;
                   _grabberPressColor = gpc;
                   _gripColor = grip;
                   _trackThickness = tt;
                   _grabberThickness = gt;
                   _easeAmount = ea;
                   _hasShine = hs;
                   init();
                   OverwriteManager.init();
              //============================================================================================================================
              private function init():void
              //============================================================================================================================
                   createTrack();
                   createGrabber();
                   createGrips();
                   addEventListener(Event.ADDED_TO_STAGE, onAddedToStage, false, 0, true);
                   _defaultPosition = Math.round(_content.y);
                   _grabber.y = 0;
              //============================================================================================================================
              public function kill():void
              //============================================================================================================================
                   stage.removeEventListener(Event.RESIZE, onStageResize);
              //============================================================================================================================
              private function stopScroll(e:Event):void
              //============================================================================================================================
                   onUpListener();
              //============================================================================================================================
              private function scrollContent(e:Event):void
              //============================================================================================================================
                   var ty:Number;
                   var dist:Number;
                   var moveAmount:Number;
                   ty = -((_cH - _tH) * (_grabber.y / _scrollValue));
                   dist = ty - _content.y + _defaultPosition;
                   moveAmount = dist / _easeAmount;
                   _content.y += Math.round(moveAmount);
                   if (Math.abs(_content.y - ty - _defaultPosition) < 1.5)
                        _grabber.removeEventListener(Event.ENTER_FRAME, scrollContent);
                        _content.y = Math.round(ty) + _defaultPosition;
                   positionGrips();
              //============================================================================================================================
              public function adjustSize():void
              //============================================================================================================================
                   this.x = _stageW - _trackThickness;
                   _track.height = _stageH;
                   _track.y = 0;
                   _tH = _track.height;
                   _cH = _content.height + _defaultPosition;
                   // Set height of grabber relative to how much content
                   _grabber.getChildByName("bg").height = Math.ceil((_tH / _cH) * _tH);
                   // Set minimum size for grabber
                   if(_grabber.getChildByName("bg").height < 35) _grabber.getChildByName("bg").height = 35;
                   if(_hasShine) _grabber.getChildByName("shine").height = _grabber.getChildByName("bg").height;
                   // If scroller is taller than stage height, set its y position to the very bottom
                   if ((_grabber.y + _grabber.getChildByName("bg").height) > _tH) _grabber.y = _tH - _grabber.getChildByName("bg").height;
                   // If content height is less than stage height, set the scroller y position to 0, otherwise keep it the same
                   _grabber.y = (_cH < _tH) ? 0 : _grabber.y;
                   // If content height is greater than the stage height, show it, otherwise hide it
                   this.visible = (_cH + 8 > _tH);
                   // Distance left to scroll
                   _scrollValue = _tH - _grabber.getChildByName("bg").height;
                   _content.y = Math.round(-((_cH - _tH) * (_grabber.y / _scrollValue)) + _defaultPosition);
                   positionGrips();
                   if(_content.height < stage.stageHeight) { stage.removeEventListener(MouseEvent.MOUSE_WHEEL, mouseWheelListener); } else { stage.addEventListener(MouseEvent.MOUSE_WHEEL, mouseWheelListener); }
              //============================================================================================================================
              private function positionGrips():void
              //============================================================================================================================
                   _grabberGrip.y = Math.ceil(_grabber.getChildByName("bg").y + (_grabber.getChildByName("bg").height / 2) - (_grabberGrip.height / 2));
                   _grabberArrow1.y = _grabber.getChildByName("bg").y + 8;
                   _grabberArrow2.y = _grabber.getChildByName("bg").height - 8;
              //============================================================================================================================
              // CREATORS
              //============================================================================================================================
              //============================================================================================================================
              private function createTrack():void
              //============================================================================================================================
                   _track = new Sprite();
                   var t:Sprite = new Sprite();
                   t.graphics.beginFill(_trackColor);
                   t.graphics.drawRect(0, 0, _trackThickness, _trackThickness);
                   t.graphics.endFill();
                   _track.addChild(t);
                   addChild(_track);
              //============================================================================================================================
              private function createGrabber():void
              //============================================================================================================================
                   _grabber = new Sprite();
                   var t:Sprite = new Sprite();
                   t.graphics.beginFill(_grabberColor);
                   t.graphics.drawRect(0, 0, _grabberThickness, _grabberThickness);
                   t.graphics.endFill();
                   t.name = "bg";
                   _grabber.addChild(t);
                   if(_hasShine)
                        var shine:Sprite = new Sprite();
                        var sg:Graphics = shine.graphics;
                        sg.beginFill(0xffffff, 0.15);
                        sg.drawRect(0, 0, Math.ceil(_trackThickness/2), _trackThickness);
                        sg.endFill();
                        shine.x = Math.floor(_trackThickness/2);
                        shine.name = "shine";
                        _grabber.addChild(shine);
                   addChild(_grabber);
              //============================================================================================================================
              private function createGrips():void
              //============================================================================================================================
                   _grabberGrip = createGrabberGrip();
                   _grabber.addChild(_grabberGrip);
                   _grabberArrow1 = createPixelArrow();
                   _grabber.addChild(_grabberArrow1);
                   _grabberArrow2 = createPixelArrow();
                   _grabber.addChild(_grabberArrow2);
                   _grabberArrow1.rotation = -90;
                   _grabberArrow1.x = ((_grabberThickness - 7) / 2) + 1;
                   _grabberArrow2.rotation = 90;
                   _grabberArrow2.x = ((_grabberThickness - 7) / 2) + 6;
              //============================================================================================================================
              private function createGrabberGrip():Sprite
              //============================================================================================================================
                   var w:int = 7;
                   var xp:int = (_grabberThickness - w) / 2;
                   var t:Sprite = new Sprite();
                   t.graphics.beginFill(_gripColor, 1);
                   t.graphics.drawRect(xp, 0, w, 1);
                   t.graphics.drawRect(xp, 0 + 2, w, 1);
                   t.graphics.drawRect(xp, 0 + 4, w, 1);
                   t.graphics.drawRect(xp, 0 + 6, w, 1);
                   t.graphics.drawRect(xp, 0 + 8, w, 1);
                   t.graphics.endFill();
                   return t;
              //============================================================================================================================
              private function createPixelArrow():Sprite
              //============================================================================================================================
                   var t:Sprite = new Sprite();               
                   t.graphics.beginFill(_gripColor, 1);
                   t.graphics.drawRect(0, 0, 1, 1);
                   t.graphics.drawRect(1, 1, 1, 1);
                   t.graphics.drawRect(2, 2, 1, 1);
                   t.graphics.drawRect(1, 3, 1, 1);
                   t.graphics.drawRect(0, 4, 1, 1);
                   t.graphics.endFill();
                   return t;
              //============================================================================================================================
              // LISTENERS
              //============================================================================================================================
              //============================================================================================================================
              private function mouseWheelListener(me:MouseEvent):void
              //============================================================================================================================
                   var d:Number = me.delta;
                   if (d > 0)
                        if ((_grabber.y - (d * 4)) >= 0)
                             _grabber.y -= d * 4;
                        else
                             _grabber.y = 0;
                        if (!_grabber.willTrigger(Event.ENTER_FRAME)) _grabber.addEventListener(Event.ENTER_FRAME, scrollContent);
                   else
                        if (((_grabber.y + _grabber.height) + (Math.abs(d) * 4)) <= stage.stageHeight)
                             _grabber.y += Math.abs(d) * 4;
                        else
                             _grabber.y = stage.stageHeight - _grabber.height;
                        if (!_grabber.willTrigger(Event.ENTER_FRAME)) _grabber.addEventListener(Event.ENTER_FRAME, scrollContent);
              //============================================================================================================================
              private function onDownListener(e:MouseEvent):void
              //============================================================================================================================
                   _pressed = true;
                   _grabber.startDrag(false, new Rectangle(0, 0, 0, _stageH - _grabber.getChildByName("bg").height));
                   stage.addEventListener(MouseEvent.MOUSE_MOVE, onMouseMoveListener, false, 0, true);
                   TweenFilterLite.to(_grabber.getChildByName("bg"), 0.5, { tint:_grabberPressColor } );
              //============================================================================================================================
              private function onUpListener(e:MouseEvent = null):void
              //============================================================================================================================
                   if (_pressed)
                        _pressed = false;
                        _grabber.stopDrag();
                        stage.removeEventListener(MouseEvent.MOUSE_MOVE, onMouseMoveListener);
                        TweenFilterLite.to(_grabber.getChildByName("bg"), 0.5, { tint:null } );
              //============================================================================================================================
              private function onMouseMoveListener(e:MouseEvent):void
              //============================================================================================================================
                   e.updateAfterEvent();
                   if (!_grabber.willTrigger(Event.ENTER_FRAME)) _grabber.addEventListener(Event.ENTER_FRAME, scrollContent, false, 0, true);
              //============================================================================================================================
              private function onTrackClick(e:MouseEvent):void
              //============================================================================================================================
                   var p:int;
                   var s:int = 150;
                   p = Math.ceil(e.stageY);
                   if(p < _grabber.y)
                        if(_grabber.y < _grabber.height)
                             TweenFilterLite.to(_grabber, 0.5, {y:0, onComplete:reset, overwrite:1});
                        else
                             TweenFilterLite.to(_grabber, 0.5, {y:"-150", onComplete:reset});
                        if(_grabber.y < 0) _grabber.y = 0;
                   else
                        if((_grabber.y + _grabber.height) > (_stageH - _grabber.height))
                             TweenFilterLite.to(_grabber, 0.5, {y:_stageH - _grabber.height, onComplete:reset, overwrite:1});
                        else
                             TweenFilterLite.to(_grabber, 0.5, {y:"150", onComplete:reset});
                        if(_grabber.y + _grabber.getChildByName("bg").height > _track.height) _grabber.y = stage.stageHeight - _grabber.getChildByName("bg").height;
                   function reset():void
                        if(_grabber.y < 0) _grabber.y = 0;
                        if(_grabber.y + _grabber.getChildByName("bg").height > _track.height) _grabber.y = stage.stageHeight - _grabber.getChildByName("bg").height;
                   _grabber.addEventListener(Event.ENTER_FRAME, scrollContent, false, 0, true);
              //============================================================================================================================
              private function onAddedToStage(e:Event):void
              //============================================================================================================================
                   stage.addEventListener(Event.MOUSE_LEAVE, stopScroll);
                   stage.addEventListener(MouseEvent.MOUSE_WHEEL, mouseWheelListener);
                   stage.addEventListener(Event.RESIZE, onStageResize, false, 0, true);
                   stage.addEventListener(MouseEvent.MOUSE_UP, onUpListener, false, 0, true);
                   _grabber.addEventListener(MouseEvent.MOUSE_DOWN, onDownListener, false, 0, true);
                   _grabber.buttonMode = true;
                   _track.addEventListener(MouseEvent.CLICK, onTrackClick, false, 0, true);
                   removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage);
                   _stageW = stage.stageWidth;
                   _stageH = stage.stageHeight;
                   adjustSize();
              //============================================================================================================================
              private function onStageResize(e:Event):void
              //============================================================================================================================
                   _stageW = stage.stageWidth;
                   _stageH = stage.stageHeight;
                   adjustSize();

  • Applying changes to multiple images . . .

    i'm relatively new to macs but i've been using aperture comfortably for the past few months.
    having just returned from a long photography trip and upgrading aperture to 1.5.1, i'm finding that i am unable to apply changes to multiple images like i used to, such as: selecting multiple images to rotate or selecting multiple images to apply the "stamp."
    when i try to "shift-select" multiple images, the change i'm trying to apply affects only the last image clicked-on in the "shift-select" grouping. does that make sense?
    has anyone else encountered this?
    mahalo nui loa
    Power Mac G5 Quad   Mac OS X (10.4.8)  

    You most likely have the Primary Only option turned on. Turn off that option in the Control Bar.

  • Applying columns to multiple playlists

    I've searched hi and low, but no luck. Is there a way to apply columns views to multiple playlists? I want to add certain columns to all my playlists (i.e. Track #) without doing it one by one.
    Any ideas?
    Bob

    Catherine, you probably have the "Primary Only" flag enabled. Press the framed litte "1" button to disable it. This flag will cause the keywords only to be applied to the current selection. Then the Keywords Controls should work as you want.
    See my user Tip here:                   Keywords or ratings are applied only to one of the selected images - why?
    What is the recommended way of applying keywords to multiple images at once?
    The Keyword Controls are fine, also dragging keywords from the Keywords HUD directly onto a selection or Batch Changing.
    Regards
    Léonie

  • Apply border to multiple frames

    I would like to know if I can apply the small border preset to all of the photos in a montage. It could save me a lot of time if I knew how to apply this to multiple frams.

    I have over 100 still photos in the timeline. I wanted each one to use the preset frame in the effects set.
    I thought I had seen that technique one time in a tutorial.
    made sense to me that you could select all stills in a timeline and drag the effect to all frames at once.
    but. . .that wasn't it.
    Original Message

  • Mask multiple movieclips from single mask

    Hi,
    h have big movieclip 450X350 and there are many small thumbnails i need to mask those from big movieclip, I need to animate those so that i can't put those in a single movieclip, Is it possible to mask multiple movieclips from single movieclip...?

    If you want to mask them using Actionscript then you should be able to place them inside a movieclip/sprite as separate animations/movieclips and then assign the mask to the container.
    You can mask multiple layers under one layer if you use the timeline

  • Aperture 3: How to apply keywords to multiple photos?

    Hi,
    I'm trying to apply keywords to multiple photos at once but if I select several photos and add a keyword in the 'metadata' panel it just gets applied to one of the selected photos, not all of them. Is this a bug or am I just doing it wrong?
    Thanks,
    Sam

    I see,
    But that requires that said keyword already exists which slows down the workflow when you're dealing with lots of new keywords, or even existing ones if you have lots and lots of keywords instead of just typing in a keyword (and it perhaps auto-completes). Also I'm somewhat of a keyboard-centric user
    Thanks for the suggestion,
    Sam

  • Applying SUBTOTAL to multiple condition SUMPRODUCT

    Hi
    I have created the following formula which works:
    =SUMPRODUCT(--($AG$10:$AG$1999<>0),$U$10:$U$1999/SUMIF($AG$10:$AG$1999,"<>"&0,$U$10:$U$1999),$X$10:X$1999)
    Column AG is a "type" filter where I've assigned 0 values to data I need to ignore when doing my sumproduct, U is my values column so the values I want to sumproduct with column X which is my return column. So this works fine to ignore my blank
    types and sumproduct the remaining values and returns to give me a total.
    However I'd like to extend this so that when I put a filter on my data the forumla holds.
    I've previously used the following for subtotals
    =SUMPRODUCT(X9:X1999,SUBTOTAL(109,OFFSET($U$9,ROW($U$9:$U$1999)-ROW($U$9),,1))/$U$7)
    but this doesn't account for the fact that I need to strip out the types that are blank which I do in the above via: --($AG$10:$AG$1999<>0)
    Is there anyway to combine these two forumlae???
    I'm trying to build the spreadsheet to be robust enough for new data to be pasted into cells A9:AG1999 each month and the required metrics pop out at the top so that others can use without having to update pivots etc. I need it dummy proofed so all they
    do is paste in new data and the forumulae do the rest!
    Any help would be greatly appreciated :O)  Happy to provide more detail if the above isn't clear!

    Try:
    =SUMPRODUCT(X$9:X$5129,SUBTOTAL(109,OFFSET($U$9,ROW($U$9:$U$5129)-ROW($U$9),,1))/SUMPRODUCT(SUBTOTAL(109,OFFSET($U$9,ROW($U$9:$U$5129)-ROW($U$9),,1)),--($AG$9:$AG$5129<>0)),--($AG$9:$AG$5129<>0))
    Solved by NVBC in the OzGrid Excel forum: tipost titled "Apply SUBTOTAL to multiple condition SUMPRODUCT inc SUMIF"

  • Multiple movieclips and mutiple event handling.

    Hi All,
    I have multiple movieclips(images sequence), which I want to add mouseevent (click and drag), keyboard event(left and right arrows) and zoom event(mouse wheel).
    I have this function for only one mc(one image sequence).
    Now if I use this function, I am having problem with calling the function from the same frame.
    That is,
    If click another mc from say frame 3, and click on another function, it should continue from frame 3 only, not start from first frame again.
    Please help.
    Thanks in advance.

    I assume that shows the part where you rotete the house view in a 360degree fashion?
    if so, make a global var on your root timeline:
    var rotationframe:int = 1; //in the beginning of the app all the dirffernt images are sitting on frame 1
    you can access this var from anywehere inside any function of your app by calling:
    root.rotationframe
    now in the function that handles the rotation (lets say its your keyboard function) in the end (after you moved the playhead) you make sure to always set
    root.rotationframe  =  garage.currentFrame;
    and in the function that handles the switching between images you write sth. like
    gotoAndStop(root.rotationframe);
    Be aware, you can`t simply use that code without adapting it to your special needs.

  • Apply Script to multiple fields

    I have a form with multiple fields that will contribute to a total. Is there a way to have script apply to multiple fields that will auto update the totals, instead of scripting a separate exit event for each field.
    Thank you

    Create a Script Object. In that object, you can have a function like this:
    function addMyFields() // add values in the fields
    var number1 = field1.rawValue;
    var number2 = field2.rawValue; // and so on
    var sumOp = number1 + number2; // + number3 + .... and so on
    totalField.rawValue = sumOp; // display sum in total field
    Paste the following code in the exit event of each field:
    ScriptObjectName.addMyFields();
    Let me know if it works for you.

  • How to apply style to multiple links?

    I'm a newbie here, so maybe this is a simplistic question.  I am having trouble applying a color style to multiple links on a webpage at the same time.  I have a page setup with a layout similar to the Drudge Report, which posts href links separated by horizontal rule lines.  I want to apply a color style to these links, but I'm finding I have to select each link individually in design mode to apply the style.  When I select multiple links in design mode, the color doesn't apply to the text.  It's time consuming to select each link individually.  I can do this easily in Microsoft Visual Web.  How can I do it in Dreamweaver?

    The best way is to put all related links into a division. 
    Let's say you want to have red links in your #header and white links in your #footer which has a black background.
    CSS, set up two sets of link styles:
    #header a {text-decoration:none}
    #header a:link {color:red}     /**unvisited**/
    #header a:visited {color:gray} /**visited**/
    #header a:hover,               /**on mouse over**/
    #header a:active,              /**on click**/
    #header a:focus                /**on tab key**/
        {text-decoration:underline}
    #footer {background: #000;}
    #footer a {text-decoration:none}
    #footer a:link {color:white}
    #footer a:visited {color:yellow}
    #footer a:hover,
    #footer a:active,
    #footer a:focus 
        {text-decoration:underline}
    HTML:
    <div id="header">
    <a href="some-link.html">Link in the header</a> |
    <a href="some-link.html">Link in the header</a> |
    <a href="some-link.html">Link in the header</a> |
    </div>
    <div  id="footer">
    <a href="some-link.html">Footer link</a> |
    <a href="some-link.html">Footer link</a> |
    <a href="some-link.html">Footer link</a> |
    </div>
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists 
    http://alt-web.com/
    http://twitter.com/altweb
    http://alt-web.blogspot.com/

  • Applying masters to multiple spreads

    Hey guys,
    Working in VB, InD CS3. I have a feeling this is like the 'ol autoflow thing, but here goes.
    I can script the application of a master to multiple pages by iterating through the pages or spreads, but it runs to slow (not that I'm impatient or anything).
    I'm wondering if there is an equivalent to using the "Apply Masters to Pages..." option from the pages panel which goes nearly instantly even on some of our longer documents.
    I thought I might be able to do this to apply masters to all pages:
    Set pgs = Ind.ActiveDocument.Spreads.ItemByRange(Ind.ActiveDocument.Spreads(1), Ind.ActiveDocument.Spreads(-1))
    pgs.AppliedMaster = Ind.ActiveDocument.MasterSpreads("LNG-TXT")
    but it errors trying to set the master, I'm sure its because pgs is a collection of masters.
    Any help is much appreciated.
    All the best,
    Ken

    It looks like you are missing .item()
    This works for me (in JS):
    app.documents[0].pages.everyItem().appliedMaster = app.documents[0].masterSpreads.item(0);

  • Applying Effect to Multiple Clips?

    Hi,
    Is there a way within Final Cut Express to apply a single effect such as Chroma Keyer to multiple clips? I've seen this done with Final Cut Pro but can't seem to replicate it in FCE.
    Thanks for your help.

    You do it exactly the same way you could do it in FCP. Drag the filter onto multiple selected clips, or copy a clip with the filter and use the paste attributes function.

  • Applying keywords to multiple photos

    seems like an easy request, right? applying a keyword to multiple photos...
    I've got the keyword HUD open. I've read the help files, the manual, seems rather straight forward to me. Select the pictures, drag over the word, should be applied to all selected.
    Problem is, I can't get that to happen.
    For example, I have a project. Under the project is a folder. I want to apply the same keyword to all 5 star pics in that folder. I use the view to display all 5 star pics. Then I select all, white box appears around them all indicating they are selected.
    But here's my crunch. Even though I selected them all, really only one picture at a time is affected, as if there is a primary selection pic within the total selected pics. I've changed views, not sure how to actually affect a change to all selected.
    It is as if the selection is a display function, but there is only one picture at a time actually selected for a change to be applied.
    How in the world does one do something so simple as select all, drag the keyword over to all selected, and see them all tagged? Seems so simple...but I can't make this happen.
    Thanks

    I agree: The help and discussions here are very valuable. Thanks for all the tips, very useful.
    For what it's worth -- I don't know why -- but one new Library I started just would not accept any Keywords at all: None. I'd click on the list I made in the Control Bar: Nothing would happen.
    BUT when going to another Library Keywords worked fine (much to my relief).
    This happen just after importing a photo from IPhoto that I had, for the first time, put keywords on it in iPhoto. Any connection, I don't know.
    BUT After going back and forth to other Libraries a few times, it started working perfectly.
    !? -- I think Aperture is great!

  • Applying security to multiple files

    I am using Acrobat X and have multiple files that I must apply/change security settings for. Is there a way to do this without having to go into every file and do them one by one? I appreciate the help.

    To create a new action, select: Tools > Action Wizard > Create New Action
    For the Steps section, select "Protection > Encrypt" from the left panel and then select the Options button and select "Password Security" as the security method. You'll then be able to set the various options you want. Save the action and you can run it on a folder of documents. Be sure to work with copies of your files. More information about working with Actions is in the Acrobat help doc, but post again if you get stuck.

Maybe you are looking for

  • Hot Synch and Mac OS 10.4.11

    My Palm m505 recently ran out of power... I plugged it ito the cradle for recharging..   I had to hit the 'reset' on the rear in order to get it up and going... but quicly found that my favourite application had "disappeared" and I returned it to the

  • 3dmark05 score too low!!!

    my 3dmark05 score is too low. i have a msi 9800 pro(green pcb version.) and i only got 1200 points please help. Also i used to get 6400 points in 3dmark03 but they also dropped to 5000. I also installed the latest chipset drivers and also have cataly

  • Error when exporting ABAP Programs and the Project

    Hi All, I keep on getting the following errors when I'm exporting the entire Project or only ABAP Programs (see attached screenshots). - Screenshot 1 shows an error when exporting a Project. - Screenshot 2 shows an error when exporting ABAP Program(s

  • Cannot not update apps because app store is telling me to sign in account and/or my apple id is disabled

    I need help updating my apps in the app store but it would not allow me since it said i need to sign in (which i did multiple times) and/or my apple id is disabled. I tried to renew everything and still won't work. Any help??

  • How do I identify which source audio file is mapped to which track in a merged clip?

    Hi there, I'm new to the merge functionality. I went ahead and merged my video/audio for a short film, all of the clips have on-camera sound, and up to 3 seperate mics. Now I find myself spending loads of time trying to match *by ear* which channel h