Skip to main content
Known Participant
January 18, 2009
Question

importing gallery into main flash file

  • January 18, 2009
  • 59 replies
  • 3226 views
i'm making my portfolio in flash, i have just about everything setup. all i need now is to import my gallery into it
i made the gallery in a seperate file so i could copy it for other sections of the gallery later on.

i've tried importing it onto the stage or into the libary but it doesn't seem to import anything apart from the items that r on stage in the gallery file. no action script. tried adding the script in myself but it doesn' seem to chg a thing!

the gallery file and code u can find here: http://www.developphp.com/Flash_tuts/AS3_Dynamic_Elastic_gallery.php

it's the same i have just with different colours and images that is all

2 more small things.

the file discription that is in the xml doesn't seem to show up letters.. if u look at the gallery example on the link above it just has 0-8 r 9. but in the xml it has something along the lines of "enter description here"
and ideas how to chg that?

is it possible once i have the file into my main file to resize it?

thx in advance
This topic has been closed for replies.

59 replies

sa22Author
Known Participant
January 20, 2009
but if i chg the paths in gallery.swf won't it not load the things it's ment 2..... like i said gallery.swf works fine

i'll try chging location now see wot happens
kglad
Community Expert
Community Expert
January 20, 2009
you need to do exactly what i said. you need to change the paths in gallery.swf or change the location of gallery and its assets.
sa22Author
Known Participant
January 20, 2009
right hold...

wot exactly do i have to do?

i'm getting confused!... all the paths in the gallery work fine, the gallery works perfect, just when i try to load it with the code i posted its just blank!
and all the paths in the main movie go to the right swf file!...??

i tried publishing the gallery then testing the main movie but still nuffin!
kglad
Community Expert
Community Expert
January 20, 2009
the gallery files don't need to be in the same folder as the embedding html, but if they are not, you need to change the paths that gallery.swf uses to find the assets it loads.
sa22Author
Known Participant
January 20, 2009
move it 2 the same file as the main movie?

it is in the same file but in a folder to help me keep it organized. but if they all need to b in the same file then i'll do that!
kglad
Community Expert
Community Expert
January 20, 2009
actionscript in gallery.swf is not ok unless you move gallery.swf and the files it loads.
sa22Author
Known Participant
January 20, 2009
in that case shouldn't i load the html file instead of the swf? or does it load the html as long as its in the same location as the swf?

i'll try it and let u know wot happens!

the AS i have already is ok tho right ?.. it should load it?

kglad
Community Expert
Community Expert
January 20, 2009
the relevant html file is the one that embeds the loading (not gallery) swf.
sa22Author
Known Participant
January 20, 2009
the gallery and xml file r in the folder!...

wot would i chg the paths to?

ah!.. html file when u said that b4 i thought u were talking about the xml file since it shows up as a html document 4 me..... i'am guessing i need to publish the gallery and load them when theres a html file telling it wot to do. right?... just though publishing it only needed to b done on the final file... but i'll give it a go and let u know wot happens!!

thx
kglad
Community Expert
Community Expert
January 20, 2009
the path to whatever gallery.swf is loading. you said, "gallery swf loads every thing apart from the scroll bar and background from a xml file".

so, there are paths to everything, including the xml file. all those paths need to be changed.

or move gallery.swf and its load-targets to the same directory as the loading swf's html file.