Flash Prof. CS5 simple photo album/slideshow template

I am trying to use the "simple photo album" template that comes with Flash Prof. CS5. I have it working except I want it to play by default. The actionscript that came with the template is below (in blue), but if I set var autoStart:Boolean = true; I get the following error and the controls do not work:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at nt_fla::MainTimeline/fl_startSlideShow()
at nt_fla::MainTimeline/frame1()
// USER CONFIG SETTINGS =====
var autoStart:Boolean = false; //true, false
var secondsDelay:Number = 2; // 1-60
// END USER CONFIG SETTINGS
// EVENTS =====
playPauseToggle_mc.addEventListener(MouseEvent.CLICK, fl_togglePlayPause);
function fl_togglePlayPause(evt:MouseEvent):void
if(playPauseToggle_mc.currentLabel == "play")
  fl_startSlideShow();
  playPauseToggle_mc.gotoAndStop("pause");
else if(playPauseToggle_mc.currentLabel == "pause")
  fl_pauseSlideShow();
  playPauseToggle_mc.gotoAndStop("play");
next_btn.addEventListener(MouseEvent.CLICK, fl_nextButtonClick);
prev_btn.addEventListener(MouseEvent.CLICK, fl_prevButtonClick);
function fl_nextButtonClick(evt:MouseEvent):void
fl_nextSlide();
function fl_prevButtonClick(evt:MouseEvent):void
fl_prevSlide();
var currentImageID:Number;
var slideshowTimer:Timer;
var appInit:Boolean;
function fl_slideShowNext(evt:TimerEvent):void
fl_nextSlide();
// END EVENTS
// FUNCTIONS AND LOGIC =====
function fl_pauseSlideShow():void
slideshowTimer.stop();
function fl_startSlideShow():void
slideshowTimer.start();
function fl_nextSlide():void
currentImageID++;
if(currentImageID >= totalFrames)
  currentImageID = 0;
gotoAndStop(currentImageID+1);
function fl_prevSlide():void
currentImageID--;
if(currentImageID < 0)
  currentImageID = totalFrames+1;
gotoAndStop(currentImageID-1);
if(autoStart == true)
   fl_startSlideShow();
   playPauseToggle_mc.gotoAndStop("pause");
} else {
  gotoAndStop(1);
function initApp(){
currentImageID = 0;
slideshowTimer = new Timer((secondsDelay*1000), 0);
slideshowTimer.addEventListener(TimerEvent.TIMER, fl_slideShowNext);
if(appInit != true){
initApp();
appInit = true;
// END FUNCTIONS AND LOGIC
Does anyone have any idea how to fix this so that the slideshow starts automatically and stops when the pause button is clicked?
Thanks,
Lisa

I finally got it to work, but had to edit the action script because it seemed to have a logic error. Here is the action script I finally used; maybe this will help you:
// USER CONFIG SETTINGS =====
var autoStart:Boolean = false; //true, false
var secondsDelay:Number = 3; // 1-60
// END USER CONFIG SETTINGS
// EVENTS =====
playPauseToggle_mc.addEventListener(MouseEvent.CLICK, fl_togglePlayPause);
function fl_togglePlayPause(evt:MouseEvent):void
if(playPauseToggle_mc.currentLabel == "play")
  fl_startSlideShow();
  playPauseToggle_mc.gotoAndStop("pause");
else if(playPauseToggle_mc.currentLabel == "pause")
  fl_pauseSlideShow();
  playPauseToggle_mc.gotoAndStop("play");
next_btn.addEventListener(MouseEvent.CLICK, fl_nextButtonClick);
prev_btn.addEventListener(MouseEvent.CLICK, fl_prevButtonClick);
function fl_nextButtonClick(evt:MouseEvent):void
if(playPauseToggle_mc.currentLabel == "pause")
  fl_pauseSlideShow();
  playPauseToggle_mc.gotoAndStop("play");
fl_nextSlide();
function fl_prevButtonClick(evt:MouseEvent):void
  fl_pauseSlideShow();
  playPauseToggle_mc.gotoAndStop("play");
fl_prevSlide();
var currentImageID:Number;
var slideshowTimer:Timer;
var appInit:Boolean;
function fl_slideShowNext(evt:TimerEvent):void
fl_nextSlide();
// END EVENTS
// FUNCTIONS AND LOGIC =====
function fl_pauseSlideShow():void
slideshowTimer.stop();
function fl_startSlideShow():void
slideshowTimer.start();
function fl_nextSlide():void
currentImageID++;
if(currentImageID > totalFrames)
  currentImageID = 1;
gotoAndStop(currentImageID);
function fl_prevSlide():void
currentImageID--;
if(currentImageID <= 0)
  currentImageID = totalFrames;
gotoAndStop(currentImageID);
if(autoStart == true)
   fl_startSlideShow();
   playPauseToggle_mc.gotoAndStop("pause");
} else {
  gotoAndStop(1);
function initApp(){
currentImageID = 0;
slideshowTimer = new Timer((secondsDelay*1000), 0);
slideshowTimer.addEventListener(TimerEvent.TIMER, fl_slideShowNext);
slideshowTimer.start();
    playPauseToggle_mc.gotoAndStop("pause");
if(appInit != true){
initApp();
appInit = true;
// END FUNCTIONS AND LOGIC

Similar Messages

  • Simple Photo Album "previous" button issue

    Hello!  I have created a slide show using the Simple Photo Album template in Flash.  All works fine except for when I click the "previous" button to view the previous slide.  When I click it, the movie skips back 3 slides instead of just one.  How can I fix this?
    Thanks!
    Jessie

    try:
    jwood_its wrote:
    Oops, here it is!
    // USER CONFIG SETTINGS =====
    var autoStart:Boolean = false; //true, false
    var secondsDelay:Number = 2; // 1-60
    // END USER CONFIG SETTINGS
    // EVENTS =====
    playPauseToggle_mc.addEventListener(MouseEvent.CLICK, fl_togglePlayPause);
    function fl_togglePlayPause(evt:MouseEvent):void
    if(playPauseToggle_mc.currentLabel == "play")
      fl_startSlideShow();
      playPauseToggle_mc.gotoAndStop("pause");
    else if(playPauseToggle_mc.currentLabel == "pause")
      fl_pauseSlideShow();
      playPauseToggle_mc.gotoAndStop("play");
    next_btn.addEventListener(MouseEvent.CLICK, fl_nextButtonClick);
    prev_btn.addEventListener(MouseEvent.CLICK, fl_prevButtonClick);
    function fl_nextButtonClick(evt:MouseEvent):void
    fl_nextSlide();
    function fl_prevButtonClick(evt:MouseEvent):void
    fl_prevSlide();
    var currentImageID:Number;
    var slideshowTimer:Timer;
    var appInit:Boolean;
    function fl_slideShowNext(evt:TimerEvent):void
    fl_nextSlide();
    // END EVENTS
    // FUNCTIONS AND LOGIC =====
    function fl_pauseSlideShow():void
    slideshowTimer.stop();
    function fl_startSlideShow():void
    slideshowTimer.start();
    function fl_nextSlide():void
    currentImageID++;
    if(currentImageID >= totalFrames)
      currentImageID = 0;
    gotoAndStop(currentImageID+1);
    function fl_prevSlide():void
    currentImageID--;
    if(currentImageID < 0)
      currentImageID = totalFrames+1;
    gotoAndStop(currentImageID+1);
    if(autoStart == true)
       fl_startSlideShow();
       playPauseToggle_mc.gotoAndStop("pause");
    } else {
      gotoAndStop(1);
    function initApp(){
    currentImageID = 0;
    slideshowTimer = new Timer((secondsDelay*1000), 0);
    slideshowTimer.addEventListener(TimerEvent.TIMER, fl_slideShowNext);
    if(appInit != true){
    initApp();
    appInit = true;
    // END FUNCTIONS AND LOGIC

  • CS5 Advanced Photo Album Template Upload Issue

    I just created a new flash ap from the template Advanced Photo Album (File->new->Templates->Media Playback->Advanced Photo Album)
    I set everything up put my photos where they needed to be and coded the xml section of the action script.  I tested it and it runs perfectly on my system.  However as soon as I upload it to my server I get the flash app to load but no images appear.  Its as if it can't find the xml file however its hardcoded into the flash app.  How can I fix this?
    Help would be greatly appreciated
    Thanks
    Stjc
    Ps all images are in the same directory as the swf and index.html files just as they were on my local machine
    Link to non working app page
    Link to non working swf
    AS Code
    import fl.data.DataProvider;
    import fl.events.ListEvent;
    import fl.transitions.*;
    import fl.controls.*;
    // USER CONFIG SETTINGS =====
    var secondsDelay:Number = 4;
    var autoStart:Boolean = true;
    var transitionOn:Boolean = true; // true, false
    var transitionType:String = "Fade"; // Blinds, Fade, Fly, Iris, Photo, PixelDissolve, Rotate, Squeeze, Wipe, Zoom, Random
    var hardcodedXML:String="<photos><image title='Exterior 1'>010.jpg</image><image title='Exterior 2'>012.jpg</image><image title='Exterior 3'>013.jpg</image><image title='Exterior 4'>014.jpg</image><image title='Exterior 5'>015.jpg</image><image title='Exterior 6'>016.jpg</image><image title='Exterior 7'>017.jpg</image><image title='Exterior 8'>018.jpg</image><image title='Kitchen 1'>019.jpg</image><image title='Kitchen 2'>020.jpg</image><image title='Kitchen 3'>031.jpg</image><image title='Dining Room 1'>021.jpg</image><image title='Dining Room 2'>022.jpg</image><image title='Basement 1'>027.jpg</image><image title='Basement 2'>028.jpg</image><image title='Great Room 1'>032.jpg</image><image title='Great Room 2'>033.jpg</image><image title='Bed Rooms 1'>034.jpg</image><image title='Bed Rooms 2'>035.jpg</image><image title='Bed Rooms 3'>036.jpg</image><image title='Bed Rooms 4'>037.jpg</image><image title='Bed Rooms 5'>038.jpg</image><image title='Bed Rooms 6'>039.jpg</image><image title='Bed Rooms 7'>040.jpg</image><image title='Bed Rooms 8'>042.jpg</image><image title='Bed Rooms 9'>043.jpg</image><image title='Bed Rooms 10'>044.jpg</image><image title='Interior 1'>041.jpg</image><image title='Interior 2'>046.jpg</image></photos>";
    // END USER CONFIG SETTINGS
    // DECLARE VARIABLES AND OBJECTS =====
    var imageList:XML = new XML();
    var currentImageID:Number = 0;
    var imageDP:DataProvider = new DataProvider();
    var slideshowTimer:Timer = new Timer((secondsDelay*1000), 0);
    // END DECLARATIONS
    // CODE FOR HARDCODED XML =====
    imageList = XML(hardcodedXML);
    fl_parseImageXML(imageList);
    // END CODE FOR HARDCODED XML
    // EVENTS =====
    imageTiles.addEventListener(ListEvent.ITEM_CLICK, fl_tileClickHandler);
    function fl_tileClickHandler(evt:ListEvent):void
    imageHolder.imageLoader.source = evt.item.source;
    currentImageID = evt.item.imgID;
    title_txt.text = imageDP.getItemAt(currentImageID).label;
    playPauseToggle_mc.addEventListener(MouseEvent.CLICK, fl_togglePlayPause);
    function fl_togglePlayPause(evt:MouseEvent):void
    if(playPauseToggle_mc.currentLabel == "play")
      fl_startSlideShow();
      playPauseToggle_mc.gotoAndStop("pause");
    else if(playPauseToggle_mc.currentLabel == "pause")
      fl_pauseSlideShow();
      playPauseToggle_mc.gotoAndStop("play");
    next_btn.addEventListener(MouseEvent.CLICK, fl_nextButtonClick);
    prev_btn.addEventListener(MouseEvent.CLICK, fl_prevButtonClick);
    function fl_nextButtonClick(evt:MouseEvent):void
    fl_nextSlide();
    function fl_prevButtonClick(evt:MouseEvent):void
    fl_prevSlide();
    slideshowTimer.addEventListener(TimerEvent.TIMER, fl_slideShowNext);
    function fl_slideShowNext(evt:TimerEvent):void
    fl_nextSlide();
    // END EVENTS
    // FUNCTIONS AND LOGIC =====
    function fl_parseImageXML(imageXML:XML):void
    var imagesNodes:XMLList = imageXML.children();
    for(var i in imagesNodes)
      var imgURL:String = imagesNodes[i];
      var imgTitle:String = imagesNodes[i].attribute("title");
      imageDP.addItem({label:imgTitle, source:imgURL, imgID:i});
    imageTiles.dataProvider = imageDP;
    imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
    title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_startSlideShow():void
    slideshowTimer.start();
    function fl_pauseSlideShow():void
    slideshowTimer.stop();
    function fl_nextSlide():void
    currentImageID++;
    if(currentImageID >= imageDP.length)
      currentImageID = 0;
    if(transitionOn == true)
      fl_doTransition();
    imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
    title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_prevSlide():void
    currentImageID--;
    if(currentImageID < 0)
      currentImageID = imageDP.length-1;
    if(transitionOn == true)
      fl_doTransition();
    imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
    title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_doTransition():void
    if(transitionType == "Blinds")
      TransitionManager.start(imageHolder, {type:Blinds, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Fade")
      TransitionManager.start(imageHolder, {type:Fade, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Fly")
      TransitionManager.start(imageHolder, {type:Fly, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Iris")
      TransitionManager.start(imageHolder, {type:Iris, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Photo")
      TransitionManager.start(imageHolder, {type:Photo, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "PixelDissolve")
      TransitionManager.start(imageHolder, {type:PixelDissolve, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Rotate")
      TransitionManager.start(imageHolder, {type:Rotate, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Squeeze")
      TransitionManager.start(imageHolder, {type:Squeeze, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Wipe")
      TransitionManager.start(imageHolder, {type:Wipe, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Zoom")
      TransitionManager.start(imageHolder, {type:Zoom, direction:Transition.IN, duration:0.25});
    } else if (transitionType == "Random")
      var randomNumber:Number = Math.round(Math.random()*9) + 1;
      switch (randomNumber) {
       case 1:
        TransitionManager.start(imageHolder, {type:Blinds, direction:Transition.IN, duration:0.25});
        break;
       case 2:
        TransitionManager.start(imageHolder, {type:Fade, direction:Transition.IN, duration:0.25});
        break;
       case 3:
        TransitionManager.start(imageHolder, {type:Fly, direction:Transition.IN, duration:0.25});
        break;
       case 4:
        TransitionManager.start(imageHolder, {type:Iris, direction:Transition.IN, duration:0.25});
        break;
       case 5:
        TransitionManager.start(imageHolder, {type:Photo, direction:Transition.IN, duration:0.25});
        break;
       case 6:
        TransitionManager.start(imageHolder, {type:PixelDissolve, direction:Transition.IN, duration:0.25});
        break;
       case 7:
        TransitionManager.start(imageHolder, {type:Rotate, direction:Transition.IN, duration:0.25});
        break;
       case 8:
        TransitionManager.start(imageHolder, {type:Squeeze, direction:Transition.IN, duration:0.25});
        break;
       case 9:
        TransitionManager.start(imageHolder, {type:Wipe, direction:Transition.IN, duration:0.25});
        break;
       case 10:
        TransitionManager.start(imageHolder, {type:Zoom, direction:Transition.IN, duration:0.25});
        break;
    } else
      trace("error - transitionType not recognized");
    if(autoStart == true)
       fl_startSlideShow();
       playPauseToggle_mc.gotoAndStop("pause");
    // END FUNCTIONS AND LOGIC

    I am havign the same problem with mine and i have tried all the suggestion on this thread, nothing is working. Still doesnt show images if I send the .swf file to a co worker. Anyone have any other ideas
    my code:
    import fl.data.DataProvider;
    import fl.events.ListEvent;
    import fl.transitions.*;
    import fl.controls.*;
    // USER CONFIG SETTINGS =====
    var secondsDelay:Number = 2;
    var autoStart:Boolean = true;
    var transitionOn:Boolean = true; // true, false
    var transitionType:String = "Squeeze"; // Blinds, Fade, Fly, Iris, Photo, PixelDissolve, Rotate, Squeeze, Wipe, Zoom, Random
    var hardcodedXML:String = "<photos><image title='Quality Coverage'>images/image1.JPG</image><image title='Money Savings'>images/image2.JPG</image><image title='Home Insurance'>images/image3.JPG</image><image title='Fred Loya has Got You Covered'>images/image4.JPG</image></photos>";
    // END USER CONFIG SETTINGS
    // DECLARE VARIABLES AND OBJECTS =====
    var imageList:XML = new XML();
    var currentImageID:Number = 0;
    var imageDP:DataProvider = new DataProvider();
    var slideshowTimer:Timer = new Timer((secondsDelay*1005), 0);
    // END DECLARATIONS
    // CODE FOR HARDCODED XML =====
    imageList = XML(hardcodedXML);
    fl_parseImageXML(imageList);
    // END CODE FOR HARDCODED XML
    // EVENTS =====
    imageTiles.addEventListener(ListEvent.ITEM_CLICK, fl_tileClickHandler);
    function fl_tileClickHandler(evt:ListEvent):void
        imageHolder.imageLoader.source = evt.item.source;
        currentImageID = evt.item.imgID;
    playPauseToggle_mc.addEventListener(MouseEvent.CLICK, fl_togglePlayPause);
    function fl_togglePlayPause(evt:MouseEvent):void
        if(playPauseToggle_mc.currentLabel == "play")
            fl_startSlideShow();
            playPauseToggle_mc.gotoAndStop("pause");
        else if(playPauseToggle_mc.currentLabel == "pause")
            fl_pauseSlideShow();
            playPauseToggle_mc.gotoAndStop("play");
    next_btn.addEventListener(MouseEvent.CLICK, fl_nextButtonClick);
    prev_btn.addEventListener(MouseEvent.CLICK, fl_prevButtonClick);
    function fl_nextButtonClick(evt:MouseEvent):void
        fl_nextSlide();
    function fl_prevButtonClick(evt:MouseEvent):void
        fl_prevSlide();
    slideshowTimer.addEventListener(TimerEvent.TIMER, fl_slideShowNext);
    function fl_slideShowNext(evt:TimerEvent):void
        fl_nextSlide();
    // END EVENTS
    // FUNCTIONS AND LOGIC =====
    function fl_parseImageXML(imageXML:XML):void
        var imagesNodes:XMLList = imageXML.children();
        for(var i in imagesNodes)
            var imgURL:String = imagesNodes[i];
            var imgTitle:String = imagesNodes[i].attribute("title");
            imageDP.addItem({label:imgTitle, source:imgURL, imgID:i});
        imageTiles.dataProvider = imageDP;
        imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
        title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_startSlideShow():void
        slideshowTimer.start();
    function fl_pauseSlideShow():void
        slideshowTimer.stop();
    function fl_nextSlide():void
        currentImageID++;
        if(currentImageID >= imageDP.length)
            currentImageID = 0;
        if(transitionOn == true)
            fl_doTransition();
        imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
        title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_prevSlide():void
        currentImageID--;
        if(currentImageID < 0)
            currentImageID = imageDP.length-1;
        if(transitionOn == true)
            fl_doTransition();
        imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
        title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_doTransition():void
        if(transitionType == "Blinds")
            TransitionManager.start(imageHolder, {type:Blinds, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Fade")
            TransitionManager.start(imageHolder, {type:Fade, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Fly")
            TransitionManager.start(imageHolder, {type:Fly, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Iris")
            TransitionManager.start(imageHolder, {type:Iris, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Photo")
            TransitionManager.start(imageHolder, {type:Photo, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "PixelDissolve")
            TransitionManager.start(imageHolder, {type:PixelDissolve, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Rotate")
            TransitionManager.start(imageHolder, {type:Rotate, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Squeeze")
            TransitionManager.start(imageHolder, {type:Squeeze, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Wipe")
            TransitionManager.start(imageHolder, {type:Wipe, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Zoom")
            TransitionManager.start(imageHolder, {type:Zoom, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Random")
            var randomNumber:Number = Math.round(Math.random()*9) + 1;
            switch (randomNumber) {
                case 1:
                    TransitionManager.start(imageHolder, {type:Blinds, direction:Transition.IN, duration:0.25});
                    break;
                case 2:
                    TransitionManager.start(imageHolder, {type:Fade, direction:Transition.IN, duration:0.25});
                    break;
                case 3:
                    TransitionManager.start(imageHolder, {type:Fly, direction:Transition.IN, duration:0.25});
                    break;
                case 4:
                    TransitionManager.start(imageHolder, {type:Iris, direction:Transition.IN, duration:0.25});
                    break;
                case 5:
                    TransitionManager.start(imageHolder, {type:Photo, direction:Transition.IN, duration:0.25});
                    break;
                case 6:
                    TransitionManager.start(imageHolder, {type:PixelDissolve, direction:Transition.IN, duration:0.25});
                    break;
                case 7:
                    TransitionManager.start(imageHolder, {type:Rotate, direction:Transition.IN, duration:0.25});
                    break;
                case 8:
                    TransitionManager.start(imageHolder, {type:Squeeze, direction:Transition.IN, duration:0.25});
                    break;
                case 9:
                    TransitionManager.start(imageHolder, {type:Wipe, direction:Transition.IN, duration:0.25});
                    break;
                case 10:
                    TransitionManager.start(imageHolder, {type:Zoom, direction:Transition.IN, duration:0.25});
                    break;
        } else
            trace("error - transitionType not recognized");
    if(autoStart == true)
       fl_startSlideShow();
       playPauseToggle_mc.gotoAndStop("pause");
    // END FUNCTIONS AND LOGIC
    /* Click to Load/Unload SWF or Image from a URL.
    Clicking on the symbol instance loads and displays the specified SWF or image URL. Clicking on the symbol instance a second time unloads the SWF or image.
    Instructions:
    1. Replace "http://www.helpexamples.com/flash/images/image1.jpg" below with the desired URL address of the SWF or image. Keep the quotation marks ("").
    2. Files from internet domains separate from the domain where the calling SWF resides cannot be loaded without special configuration.
    imageHolder.addEventListener(MouseEvent.CLICK, fl_ClickToLoadUnloadSWF);
    import fl.display.ProLoader;
    var fl_ProLoader:ProLoader;
    //This variable keeps track of whether you want to load or unload the SWF
    var fl_ToLoad:Boolean = true;
    function fl_ClickToLoadUnloadSWF(event:MouseEvent):void
        if(fl_ToLoad)
            fl_ProLoader = new ProLoader();
            fl_ProLoader.load(new URLRequest("http://www.helpexamples.com/flash/images/image1.jpg"));
            addChild(fl_ProLoader);
        else
            fl_ProLoader.unload();
            removeChild(fl_ProLoader);
            fl_ProLoader = null;
        // Toggle whether you want to load or unload the SWF
        fl_ToLoad = !fl_ToLoad;
    /* Click to Load/Unload SWF or Image from a URL.
    Clicking on the symbol instance loads and displays the specified SWF or image URL. Clicking on the symbol instance a second time unloads the SWF or image.
    Instructions:
    1. Replace "http://www.helpexamples.com/flash/images/image1.jpg" below with the desired URL address of the SWF or image. Keep the quotation marks ("").
    2. Files from internet domains separate from the domain where the calling SWF resides cannot be loaded without special configuration.
    imageHolder.addEventListener(MouseEvent.CLICK, fl_ClickToLoadUnloadSWF_2);
    import fl.display.ProLoader;
    var fl_ProLoader_2:ProLoader;
    //This variable keeps track of whether you want to load or unload the SWF
    var fl_ToLoad_2:Boolean = true;
    function fl_ClickToLoadUnloadSWF_2(event:MouseEvent):void
        if(fl_ToLoad_2)
            fl_ProLoader_2 = new ProLoader();
            fl_ProLoader_2.load(new URLRequest("http://www.helpexamples.com/flash/images/image1.jpg"));
            addChild(fl_ProLoader_2);
        else
            fl_ProLoader_2.unload();
            removeChild(fl_ProLoader_2);
            fl_ProLoader_2 = null;
        // Toggle whether you want to load or unload the SWF
        fl_ToLoad_2 = !fl_ToLoad_2;

  • IWeb and Photo Album/Slideshows

    My apologies if this topic has been done before. But I didn't find anything specific to answer my question here on the board.
    For starters, I'm new to iWeb. Actually, aside from a .MAC account I'm new to web design period. I was wondering if someone could walk me through the process of adding a slideshow or photo album to my yet to be published iWeb site.
    Thanks in advance,
    John Hansen
    1.67GHZ 15 Powerbook G4 w/ 128Mg VR 10.4.1   Mac OS X (10.4.3)  

    HI John,
    The iWeb support site is a great place to start learning.
    Don't forget to click on the iWeb tutorials "start here" link.
    Have fun!
    http://www.apple.com/support/iweb/

  • ICab - HomePage Photo Albums/Slideshows

    I've been trying iCab recently and have encountered a problem with HomePage albums and slideshows. (No problems in WaMCom and IE.)
    iCab support replies have been helpful but produced no solutions.
    Clicking on a HomePage photo album thumbnail opens the slideshow window but no picture loads, the activity wheel just spins. The browser then 'half stalls': windows can be closed and menus are available but no page can be loaded via link or URL. This happens using all identities.
    However if I click on 'Start Slideshow' that works OK with identity set to iCab, Firefox or Safari. But as Opera or IE the slide show starts, but with no picture, just a tiny frame where the pic should be.
    Broadband, no firewall. iCab memory set to 75000.
    Any thoughts, please?
    Michael

    Great photos!
    The slideshow works with iCab 3 (OS X and Classic), and iCab 2.9 (using Classic).
    Clicking thumbnails works with iCab3 (OS X) and iCab 2.9 in Classic, BUT clicking thumbnails doesn't work with iCab 3 using Classic. (I'm not booting into OS 9 to check this out;-) This was with iCab using the default preferences.
    I'll double-check this in the morning with the non-public iCab ß423. If it still doesn't work, I'll email Alex. It's probably JavaScript related, but I believe the InScript engine has been updated since the last public beta, so I'll have to check that out first.
    I'll post back.

  • Cs5 Advanced Photo Album Template Live Links

    I'm using this template as a "quick & dirty" content slider for my website. I got everything to work great, there's no issues with it's functionality or actionscript. I would just like to make each image a "clickable" link. I got 4 images that I want to take users to 4 separate webpages, I've searched and searched for answers but most are over my head. Is there anybody that could help me? Here's the actions:
    import fl.data.DataProvider;
    import fl.events.ListEvent;
    import fl.transitions.*;
    import fl.controls.*;
    // USER CONFIG SETTINGS =====
    var secondsDelay:Number = 7;
    var autoStart:Boolean = true;
    var transitionOn:Boolean = true; // true, false
    var transitionType:String = "Fade"; // Blinds, Fade, Fly, Iris, Photo, PixelDissolve, Rotate, Squeeze, Wipe, Zoom, Random
    var hardcodedXML:String="<photos><image title='Your Choice'>image1.jpg</image><image title='Quick Option'>image2.jpg</image><image title='New Product'>image3.jpg</image><image title='Get Started'>image4.jpg</image></photos>";
    // END USER CONFIG SETTINGS
    // DECLARE VARIABLES AND OBJECTS =====
    var imageList:XML = new XML();
    var currentImageID:Number = 0;
    var imageDP:DataProvider = new DataProvider();
    var slideshowTimer:Timer = new Timer((secondsDelay*1000), 0);
    // END DECLARATIONS
    // CODE FOR HARDCODED XML =====
    imageList = XML(hardcodedXML);
    fl_parseImageXML(imageList);
    // END CODE FOR HARDCODED XML
    // EVENTS =====
    imageTiles.addEventListener(ListEvent.ITEM_CLICK, fl_tileClickHandler);
    function fl_tileClickHandler(evt:ListEvent):void
        imageHolder.imageLoader.source = evt.item.source;
        currentImageID = evt.item.imgID;
    playPauseToggle_mc.addEventListener(MouseEvent.CLICK, fl_togglePlayPause);
    function fl_togglePlayPause(evt:MouseEvent):void
        if(playPauseToggle_mc.currentLabel == "play")
            fl_startSlideShow();
            playPauseToggle_mc.gotoAndStop("pause");
        else if(playPauseToggle_mc.currentLabel == "pause")
            fl_pauseSlideShow();
            playPauseToggle_mc.gotoAndStop("play");
    next_btn.addEventListener(MouseEvent.CLICK, fl_nextButtonClick);
    prev_btn.addEventListener(MouseEvent.CLICK, fl_prevButtonClick);
    function fl_nextButtonClick(evt:MouseEvent):void
        fl_nextSlide();
    function fl_prevButtonClick(evt:MouseEvent):void
        fl_prevSlide();
    slideshowTimer.addEventListener(TimerEvent.TIMER, fl_slideShowNext);
    function fl_slideShowNext(evt:TimerEvent):void
        fl_nextSlide();
    // END EVENTS
    // FUNCTIONS AND LOGIC =====
    function fl_parseImageXML(imageXML:XML):void
        var imagesNodes:XMLList = imageXML.children();
        for(var i in imagesNodes)
            var imgURL:String = imagesNodes[i];
            var imgTitle:String = imagesNodes[i].attribute("title");
            imageDP.addItem({label:imgTitle, source:imgURL, imgID:i});
        imageTiles.dataProvider = imageDP;
        imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
        title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_startSlideShow():void
        slideshowTimer.start();
    function fl_pauseSlideShow():void
        slideshowTimer.stop();
    function fl_nextSlide():void
        currentImageID++;
        if(currentImageID >= imageDP.length)
            currentImageID = 0;
        if(transitionOn == true)
            fl_doTransition();
        imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
        title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_prevSlide():void
        currentImageID--;
        if(currentImageID < 0)
            currentImageID = imageDP.length-1;
        if(transitionOn == true)
            fl_doTransition();
        imageHolder.imageLoader.source = imageDP.getItemAt(currentImageID).source;
        title_txt.text = imageDP.getItemAt(currentImageID).label;
    function fl_doTransition():void
        if(transitionType == "Blinds")
            TransitionManager.start(imageHolder, {type:Blinds, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Fade")
            TransitionManager.start(imageHolder, {type:Fade, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Fly")
            TransitionManager.start(imageHolder, {type:Fly, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Iris")
            TransitionManager.start(imageHolder, {type:Iris, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Photo")
            TransitionManager.start(imageHolder, {type:Photo, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "PixelDissolve")
            TransitionManager.start(imageHolder, {type:PixelDissolve, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Rotate")
            TransitionManager.start(imageHolder, {type:Rotate, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Squeeze")
            TransitionManager.start(imageHolder, {type:Squeeze, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Wipe")
            TransitionManager.start(imageHolder, {type:Wipe, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Zoom")
            TransitionManager.start(imageHolder, {type:Zoom, direction:Transition.IN, duration:0.25});
        } else if (transitionType == "Random")
            var randomNumber:Number = Math.round(Math.random()*9) + 1;
            switch (randomNumber) {
                case 1:
                    TransitionManager.start(imageHolder, {type:Blinds, direction:Transition.IN, duration:0.25});
                    break;
                case 2:
                    TransitionManager.start(imageHolder, {type:Fade, direction:Transition.IN, duration:0.25});
                    break;
                case 3:
                    TransitionManager.start(imageHolder, {type:Fly, direction:Transition.IN, duration:0.25});
                    break;
                case 4:
                    TransitionManager.start(imageHolder, {type:Iris, direction:Transition.IN, duration:0.25});
                    break;
                case 5:
                    TransitionManager.start(imageHolder, {type:Photo, direction:Transition.IN, duration:0.25});
                    break;
                case 6:
                    TransitionManager.start(imageHolder, {type:PixelDissolve, direction:Transition.IN, duration:0.25});
                    break;
                case 7:
                    TransitionManager.start(imageHolder, {type:Rotate, direction:Transition.IN, duration:0.25});
                    break;
                case 8:
                    TransitionManager.start(imageHolder, {type:Squeeze, direction:Transition.IN, duration:0.25});
                    break;
                case 9:
                    TransitionManager.start(imageHolder, {type:Wipe, direction:Transition.IN, duration:0.25});
                    break;
                case 10:
                    TransitionManager.start(imageHolder, {type:Zoom, direction:Transition.IN, duration:0.25});
                    break;
        } else
            trace("error - transitionType not recognized");
    if(autoStart == true)
       fl_startSlideShow();
       playPauseToggle_mc.gotoAndStop("pause");

    Without writing the code for you, the general idea is knowing what the image number is. That seems to be your issue. Your click events need to be able to extract the name of the image that was clicked (who's instance name can have that number in it). Based on that number you can determine what to do.
    Any MouseEvent.CLICK function handlers will give you the name (if you set it) of what was clicked.
    e.g.
    import flash.display.Sprite;
    import flash.events.MouseEvent;
    var a:Sprite = new Sprite();
    a.beginFill(0xFF0000,1);
    a.graphics.drawRect(0,0,100,100); // draw red rectangle
    a.graphics.endFill();
    addChild(a);
    // give it a name
    a.name = "a_1";
    a.addEventListener(MouseEvent.CLICK, handleClick);
    // Now on a click, extract the name and use it:
    function handleClick(e:MouseEvent):void
         // what button was clicked?
         trace(e.target.name);
         // get the number
         var num:int = int(e.target.name.toString().split('_')[1]);
         trace("Button #" + num + " clicked");
         // do something based on the number
         if (num == 1)
              // do something based on button 1
         else if (num == 2)
              // do something based on button 2
         // etc...

  • How to convert iWeb photo album slideshows into iMovies?

    iLife '06/iMovie HD 6
    I have some slide shows that would probably be much more interesting if I converted them into iMovies with transitional effects, music, etc.
    I bought iLife '06 and Tiger in July, '06 and now have my website up and running but aside from making an iMovie out of my footage taken with my Sony digital video camera recorder (DCR-TRV 11) I want to make those still slideshows more interesting.
    My website is: http://web.mac.com/lorna6
    You'll see that I have several slideshows with still photographs.
    I have SEEN iMovies which are made with stills, so I know that it is possible; I just don't know how to do it, and have never worked with iMovie.
    If you know of a site (other than the Apple tutorials) that is good for teaching beginners, please, could you let me know? Thank you.
    Lorna in Southern California

    Oh oh. I just now found an Apple tutorial that mentions using photos with iMovie. I think that I might have found what I was earlier requesting. Sorry sorry. Lorna in Southern California

  • Advanced photo album template

    Adobe Flash Professional CS5, advanced photo album template
    Hi there,
    Hope someone can help me with this easy question.
    When I use the test movie function  working with the advanced photo album template my photos can not be found. I get the error message "Error #2044: Ej hanterad ioError:. text=Error #2035: URL:enhittades inte. URL: file:"
    I've checked the spelling of the filenames, I use for the photos:  image1.jpg, image2.jpg etc. so the filenames should be correct.
    Also all the files are in the same folder, both the fla-files and the image files.
    I'm using a 64 bit Windows 7 operating system, but except for this snag the program seems to be working perfectly ok..
    Getting weary of all the time consuming problems.
    Hoping someone can straighten this one out for me.
    br/Mats Jacobsson

    Code for updating the title is missing. Add following line of code inside function fl_tileClickHandler()
    title_txt.text = imageDP.getItemAt(currentImageID).label;

  • Advanced Photo Album SWF Movies Playback

    Hello
    I linked an .swf movie into the Flash CS5 Advanced Photo Album template and have found that if I press the "next" button, the movie continues to play. You can't go back to it.
    Does anyone have a tip to stop a .swf movie when I proceed to the next one?

    Hello
    I linked an .swf movie into the Flash CS5 Advanced Photo Album template and have found that if I press the "next" button, the movie continues to play. You can't go back to it.
    Does anyone have a tip to stop a .swf movie when I proceed to the next one?

  • Web photo album - source image folder empty

    I am using Vista and CS4.
    I am trying to create a web photo album.
    When I select Browse in the Source images folder, and navigate to my image folder (which has over 60 jpeg images in it), the dialog box in Dreamweaver says the folder is empty.
    I tried to save the photo as other formats, gif, png, etc to no avail; it still says the folder is empty.
    Can anybody give me something to try?

    I create photo albums and the only thing I can suggest is when you get to the folder, you have to open the folder, then it will say SELECT at the bottom of the window. If you upgrade to CS5, Create Photo Album has been removed for some reason.

  • Best way to insert non-flash photo album in Dreamweaver CS5.5

    Using Dreamweaver CS4, I created my wife's art website.  It is:  www.tanglewoodbrushstrokes.com
    To insert photo albums, I used Bridge and Fireworks.  Once past the initial learning curve, I was able to create these albums fairly easily.  However, these albums have two limitations that I would like to address.
    1.  Adding or deleting an image requires creating a new album and then posting it on the page.  Now that I have practice, it doesn't take me very long to do this but there must be a simpler way.  As you will see on my wife's site, she has many pages of photo albums.  Moving photos from her "Recent Creations" page means those images my be disbursed over three or four different albums.  So this can be very time consuming.
    2.  The albums created in this manner are flash galleries and are not visible on Iphones or Ipads.
    I recently purchased Dreamweaver CS5.5 so I could use HTML5 in order to make my site work on Iphones and Ipads as well as PC's.  I have nearly completed the tutorial and am about ready to create a new site.  Today I have done some searching for ways to use non-flash galleries and have not come up with a definitive answer.
    As you can see on my wife's website, the galleries are fairly simple.  All I really need is a page of thumbnails leading to a larger image with a description.  I want to keep it that way.
    Any suggestions?

    There is no one size fits all solution to this.  You're using DW to make a gallery and it's not really a gallery creation tool per se.  It's web authoring software.  So whichever gallery solution you choose it's going to come from someplace else.  And then you must integrate it into your HTML pages.
    Personally, I really like dynamic slideshows with jQuery.  Add some PHP code to your page.  Upload jQuery   scripts and optimized images to your server.  Done.
    To swap images later, add/delete files from image folder on server. Done.
    You can see a live demo of this below:
    http://alt-web.com/DynamicSlides/
    http://jalbum.net/
    If you want to generate a lot of different galleries quickly, look at JAlbum.  It's a commercial product that creates the thumbnail images & HTML pages for you.  There are lots of skins (styles) to choose from and you can further customize layouts with CSS.
    http://www.projectseven.com/products/galleries/ssm/index.htm
    PVII Slide Show Magic - extension for Dreamweaver
    jQuery Fancy Box ~
    http://fancybox.net/
    57 Free Image Gallery Solutions with jQuery ~
    http://www.1stwebdesigner.com/css/57-free-image-gallery-slideshow-and-lightbox-solutions/
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists 
    http://alt-web.com/

  • Adding transitions to Flash Photo Slideshow template?

    I'm working on generating a template i can use to just drop in photos from shoots for a blog where i discuss the types of projects my team does.
    I like the flash slideshow template because once it's all set up the way you want it you can just drop all the photos in on import.
    I got everything pretty much tweaked out how i want it - got rid of the controller ball and put the controls and counter on the frame, got it to auto start with the pause/play toggle working correctly (thanks to this forum)
    BUT
    now i want to add a transition between photos.
    I'm thinking I want to extend the number of frames each photo is on stage for add a new layer with a white or black solid and have that fade in and out so that i really can just import in the new images in each time and not require more tweaking but i can't figure out how to change the advance code to say something like "current frame + 15" and set the counter up so it's not affected by the new frames...
    I'd like to leave the photo key frames as unmodified as possible so that in the future it really is just a question of dropping in new photos for each blog post...
    ideas?

    Jim,
    You have two ways of doing this,
    1.You can put the pictures into Photoshop / Photoshop Element and use the text tool to add your captions.
    You can do it in any color or font and then drag it right into iDVD.
    2.or do it in iMovie - You have a wide assortment of titles in iMovie. Just uncheck the over black square, I would use the Subtitle, write in the space provided and then pull down the word T Subtitle in front of the picture where you want the titles to appear. Adjust the time with the bar on top. You have a choice of color also. Then put it into iDVD.

  • How make a slideshow that mimics a photo album (book)

    For the past year I've been using FCE to make simple slideshows and I want to attempt something a bit more difficult now (but not too hard <grin>).
    I want to create a slideshow that mimics looking through a photo album. On each page of the "book" you would see some number of photos, then the page would turn. Does this seem like a good learning project?
    I can visualize what I want, but there are some things I can't figure out how to accomplish.
    1. How can I create a "book cover" and have it open. Book covers open stiffly, so a page peel effect isn't quite the right thing.
    2. For the "pages", I want photos on a background that looks like paper. Then the background needs to turn - not just the individual photos. How could I make a background? Oh, and some of those "photos" will be video clips. Does that make any difference?
    Any suggestions would be appreciated. Pointers to applicable tutorials are especially welcome.
    thanks in advance,
    -Mike

    Hi(Bonjour)!
    Try this workflow:
    In Photoshop, create a template document with a scanned paper texture on background. Start with a mid size document like 1066 X 800 (it fits 4:3 aspect ratio) pixels frame size. Add scaled down photos on layers to compose the presentation on the page itself. You can event add some black paper corners on each photo. Flatten the PSD document and save it as PICT or PNG. Repeat this process for each desired page of your slide show and create a cover for the album.
    Import all these documents in FCE and edit your stills in timeline with correct duration. Add a simple page peel transition(with small curl value) or a horizontal barn door transition at each edit, and voilà.
    Michel Boissonneault

  • What is your favorite flash photo album?

    Looking to see what people are using for flash photo albums.
    I know I scan search for google and I know if I had flash I could
    make it. I dont have it, I have cold fusion and I program cold
    fusion, but for my needs I want to use flash.
    I like an automated slideshow function with forward back
    buttons, watermarking.
    Loaded through URL variables or through a text file is fine
    as I can deal with that through Cold Fusion.
    Free open source code is preferred, but I would like to know
    what people are using.
    Thanks!
    KM

    Can you please suggest a better software to purchase that if much more "user friendly" and creates a high quality product?
    No.
    using Macs since '86, I've seen PaintBoxes and Quantel systems at work, sit aside when Masters used Premiere Pro, I do own & use FCE… I have knowledge of Hyperengine, and Avid free …-
    I never saw a simpler metaphor then "sorting slides" as in iM; most post we read here are, because people start to edit their movies with zero-manual-reading…- which works in 90% of cases…
    and, iM supports the same codec as any miniDV camcorder (or even HD)… => not bit gets lost in quality…
    more user friendly with high quality?
    no idea...... (even with less quality…)
    (iM has its hurdles and some real bugs, ask forum members Matti or Karl… but for me, the average user - no problems so far....)

  • Modern Photo Slideshow template help, please...

    Hi guys and gals... Happy Thanksgiving! Now, back to work,
    right? Yikes!
    First time questioner, and I think I've done my due diligence
    on searches, etc, but...
    I am getting back into Flash usage after a few years off, so
    I am pretty rusty. I'm stepping on the
    Modern Photo Slideshow template that comes with CS3, and am
    almost done! I've resized, deconstructed the god-awful controller
    down to something simple and elegant, added all my client's 27
    images, set the publisher to play=true...
    BUT, I can't seem to break the code: I'm trying to get it to
    start in Autoplay=1 mode (play on download), but it keeps skipping
    the first frame. I've tried quite a few very simple code tweaks,
    like changing various zeroes to ones, but can't seem to find the
    rosetta stone.
    If I simply add a null frame to the beginning, so that image
    1 is at frame 2, it goofs up the framecount, as well as the looping
    elegance. I guess that would be fine, if I could figure out the
    proper syntax for making the framecount display (i.e.: 1 of 27)
    equal to framecount-1 to compensate for the null frame at the
    beginning. However, that 's just a Big Hammer method of solving my
    problem. Surely there is a more effective and proper way?
    Summary: All I really want it to do is start in
    autoplayStatus=1 without blowing past the first image.
    Anyone know if this is a simple code tweak? I'm so close, I'd hate
    to switch to a different template, as the client loves what I've
    currently got.
    Thanks so much!

    Found the answer: when you double-click the mc, controller
    sitting on the stage, there is a frame script that has about 58
    lines of code. Sitting at the bottom is
    autoplayStatus = 0;. When you set the value to 1 (one) and
    test the movie, is starts in auto-play mode.

Maybe you are looking for

  • Scart- cable to thunderbolt

    Hi guys! Just wondering if anyone know if there's any cables that has scart to thunderbolt? So you could, for examle connect your xbox 360 to your Thunderbolt display and use that as your primary screen.

  • Education bought macbook air for commercial use

    Hi, I'm part time student and full time software engineer developing proprietary software. Recently I've placed an order for macbook air through education store. I've came across this statement "By clicking on this check box, I represent that I have

  • Branch Assignment

    Hi Friends, I would like to know a few things about Brach Assignment. I have a requirement to assign value to an attirbute (automatically - via workflow). Could we use branch assignment for this? I created a branch assignment for the same, but it doe

  • Routings and Work Centers Transfer using ALE

    Can anbody has written inbound function modules for Routing and Workcenters  using message types LOIROU and LOIWCS using ALE Transaction POIM High points will be rewarded.

  • Music folders..?

    im really confused. i have an "itunes music folder" but i have no songs in it. i had saved my songs all in this other folder in my "my music" folder. i got itunes to read all the songs, and put them in the library. now before i mention my problem, i