|
|
|
#1 |
|
Junior Member
Join Date: Feb 2003
Posts: 11
|
Please help, question on actionscript
I got to load a list of JPGs in a swf, for the code I'm currently using:
MovieClip1.loadMovie("S0001.JPG"); MovieClip1.loadMovie("S0002.JPG"); MovieClip1.loadMovie("S0003.JPG"); But in the real suitation, I need is to load JPGs in MovieClip1, and by pressing Button "Next","Next x2", "Previous" and "Previous x2", it will have an action. i.e. MovieClip1 -> loads S0001.JPG as default After clicking "Next" MovieClip1 -> loads S0002.JPG After clicking "Next x2" MovieClip1 -> loads S0004.JPG After clicking "Previous" MovieClip1 -> loads S0003.JPG After clicking "Previous x2" MovieClip1 -> loads S0001.JPG and so on How can I make the variable (S0001.JPG) split into "S"+"####"+".JPG" which the "####" can be a bigger or smaller number by a function in the button? Please note that the list of JPGs must be in this format of naming, "S"+"####"+".JPG" Please help! |
|
|
|
|
|
#2 |
|
Senior Member
Join Date: Apr 2004
Posts: 189
|
try this
__________________
some smart citation is coming here soon |
|
|
|
|
|
#3 | |
|
Junior Member
Join Date: Jul 2004
Location: Malaysia
Posts: 8
|
Quote:
if you follow eraser_ad's coding, you must change your jpeg file name to S1.jpg, S2.jpg...etc. If you don't want to change you can use like this:
|
|
|
|
|
|
|
#4 |
|
Junior Member
Join Date: Feb 2003
Posts: 11
|
Thanks Eraser-ad and Insane-Tomato
You guys really helped me a lot! |
|
|
|
|
|
#5 |
|
Senior Member
Join Date: Apr 2004
Posts: 189
|
thx Insane Tomato
I actually just learned something new from here too. Thanks
__________________
some smart citation is coming here soon |
|
|
|
![]() |
|
||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|