Imajine Blog Imajine Articles
Contact Me

Scrapbook Photo Gallery tutorial in Flash


Goodie!! We will learn three flash behaviors while creating this eye-catching photo gallery and they are -
  • Load external graphic behavior ,
  • On-click behavior to lift photograph right on top and
  • Drag -and- drop behavior
Let’s begin the tutorial,
  • Import and use any background you like
  • Next ,we will have to create a movie clip to hold the photograph,
    Please follow the steps below to create the same,
    1. Create a movie clip symbol and name it ‘pic_mc’

    2. Now in this movie clip symbol, create a larger white square vector graphic, which will behave as a photo border. Lock this layer and create a new layer above the same and create a gray colored square vector graphic which is smaller than the white one and align it center to the white one.

    3. Select this gray square vector graphic and convert it to a movie clip symbol and give it an instance name ‘photo’. This movie clip is now done, return to main ‘scene1’.
  • Now drag this movie clip ‘pic_mc’ into your canvas and name it ‘pic1’,
  • Likewise, drag three more and name them ‘pic2’, ‘pic3’ and ‘pic4’.
  • Move the 4 images and name them ‘pic1’, ‘pic2’, ‘pic3’ and ‘pic3’ into the directory where this flash source file resides.

Actionscripting –

Load external graphic behavior

  • Insert another new layer in your flash file and name it ‘actions’.
  • Select ‘Frame1’ of actions layer and paste below script in your actions window.

    //load Graphic Behavior
    this.pic1.photo.loadMovie("pic1.jpg");
    //End behavior

    //load Graphic Behavior
    this.pic2.photo.loadMovie("pic2.jpg");
    //End behavior

    //load Graphic Behavior
    this.pic3.photo.loadMovie("pic3.jpg");
    //End behavior

    //load Graphic Behavior
    this.pic4.photo.loadMovie("pic4.jpg");
    //End behavior

On-click behavior to lift photograph right on top and drag and drop behavior

  • Select each movie clip and paste the below script in the actions window

    on (press)
    {
    //Start Dragging Movieclip Behavior
    startDrag(this);
    //End behavior

    //Bring to Front Behavior
    mx.behaviors.DepthControl.bringToFront(this);
    //End behavior
    }

    on (release)
    {
    //Stop Dragging Movieclip Behavior
    stopDrag();
    //End behavior
    }


Press 'Ctrl+Enter' to view the your Scrapbook photo gallery.

Click here to download source file

You can also view other Flash Photo Galleries at
My photographs and Pranav

Tags: Flash photo gallery, load external images, drag and drop, actionscript photo gallery 

Download Free Photo Gallery

Download Free Photo Gallery

You can download Imajine's Scrapbook Photo Gallery absolutely free of cost and to customize , you need no knowledge of Adobe Flash.  Click here to view Scrapbook Photo Gallery / download

Tutorials
Flash Tutorials
Horizontal 3D Carousel
MP3 Player
Scrapbook Photo Gallery
Text Enhancement
Color object
Glow effect using actionscript
Drawing with actionscript
Blur Effect
Load external .mp3 file
Preload external .mp3 file
Sound Controller
Set volume of externally .mp3 file
View MP3 song details
Actionscript blur effect
Actionscript fade in / out effect
Fireworks Tutorials
Custom Stroke
Typography / Ink blot effect
Photograph focus effect
Rainbow Pattern
Inset Text Effect
Fuzzy Light Blending Mode
Little bulb effect
Old paper effect
'Post it' effect
Hand drawn designs
Black/White and Sepia tone
Water color painting effect
Vintage effect on vector graphics
Solid color, black/white
Photoshop Tutorials
Photo editing
Purple Haze

Portfolio

Logos
Website design
CMS Customization
Flash
Web development
Print


Download free textures and patterns and use it for your personal use.

Click here to download Textures and Patterns.

Download free birthday cards

Free Birthday Cards
Click here to view Imajine's free downloadable birthday cards for personal and corporate use. Imajine's birthday cards are in jpeg format so it is faster to download and send in your wishes to your friends and family.
Bookmark and Share Tell a Friend jayanthi.varma@imajine.in  |  © 2008 Imajine