Log in

View Full Version : help with a scrolling image gallery



RussellBishop
05-08-2008, 12:24 AM
Hi everyone !

I'd really appreciate your help with this gallery, i've used a web-based tutorial to produce this gallery, and the client wants several of them, but with different amounts of images. I mastered the one with 15, but trying to change the code has become disastrous. Here are the links, the 'portrait' files are fine, but it's the 'advertising' files that I'm struggling with;

portrait.fla (http://www.russbishop.net/downloads/portrait.fla)
portrait.swf (http://www.russbishop.net/downloads/portrait.swf)

advertising.fla (http://www.russbishop.net/downloads/advertising.fla)
advertising.swf (http://www.russbishop.net/downloads/advertising.swf)

Thanks so much in advance !

Russell Bishop

Medyman
05-08-2008, 12:40 AM
Hi Russell...

Scrolling thumbnail panel, eh...I've never heard of such a thing. :p

First, your .fla is very easy to change. You only have to change one number to alter the scrolling distances. But let me offer you some advice (though unsolicited as it is) first.

How many of these things do you have to do? If it's many more, might I suggest just creating one dynamic flash file. If you need granular control over images, you can use XML. The more of these movies that you add to a page, you're going to get performace hits. Taking the images out of the .fla and making it dynamic will free up a lot of resources for you (including your time).

Just my two cents.

Now for your solution.

In advertising.fla:

// call function xpos
x_pos = xpos(900,.75);
with (menu)
{
_x += (x_pos - _x)*.4;
}

}

That'll make it work. For future versions, just play around with the highlighted number. That's all you need to do.

RussellBishop
05-08-2008, 01:31 AM
Brilliant, thankyou Medyman, i'll give this a go.

I'm not yet knowledgeable in XML-driven flash, I really must learn.

Medyman
05-08-2008, 01:51 AM
I'm not yet knowledgeable in XML-driven flash, I really must learn.

Mmhmm...It's a huge timesaver. And a winner for clients to maintain their own websites.

I'd recommend viewing Lee Brimelow's video tutorials on XML over at gotoandlearn.com. That's what got me started with XML.

hyk
05-08-2008, 08:12 AM
Hi RussellBishop.

Maybe you could take a look at this. tutorials on Flash 8 (http://www.kirupa.com/developer/flash/index.htm)

:)

RussellBishop
05-09-2008, 03:15 PM
Thanks very much for your help guys, great forum here :D

RussellBishop
05-11-2008, 09:15 PM
Problem: Unfortunately after changing that number, it seems that whatever code controls how and when the gallery stops scrolling is incorrect. Is anyone able to edit the .fla themselves and send it to me?

Russell Bishop

Medyman
05-12-2008, 03:24 AM
Hi Russell,

I tried playing around with your examples some more. I see what you're talking about as far as the scrolling being incorrect. I have a hunch about what's causing it but I really don't understand some of the techniques that are used here (the syntax is AS1.0 so maybe that's why...that's before my time :p)

You said this is from a web-tutorial. Could you point out which tutorial that was so I can understand the code and help you fix it to your needs?

Alternately, I can show you a different technique to do the same thing where you wouldn't have to edit the flash file per scrolling panel. So all you would have to do is change the images and the ActionScript could figure out all the calculations by itself.