Ask a Question related to Macromedia Flash Data Integration, Design and Development.
-
antonioStarms #1
Need help scrolling dynamic content from XML
I am trying to make a photo gallery and I have succeed in importing the
pictures from XML into Flash. There are still two problems:
1. The content is loading into a movieclip and I tried to place a scroll pane
on the stage to adding scrolling capabilities. I set the parameters to control
the movieclip that holds the thumbnails but it is not making a scroll bar. I
can see the pictures inside of the scroll pane but it will not scroll to show
the rest of the pictures.
2. I can not figure out how to space the thumbnails evenly. I made a variable
and multiplied the x position of each picture by it but there are large
differences between landscape and portrait pictures.
Thanks for the help
myPhoto = new XML();
myPhoto.ignoreWhite = true;
myPhoto.load("events.xml");
myPhoto.onLoad = function(success) {
numimages = this.firstChild.childNodes.length;
spacing = 70;
for (i=0; i<numimages; i++) {
this.picHolder = this.firstChild.childNodes[i];
this.thumbHolder = thumbnails.createEmptyMovieClip("thumbnail"+i, i);
this.thumbHolder._x = i*spacing;
this.thumbLoader = this.thumbHolder.createEmptyMovieClip("thumbnail_i mage",
0);
this.thumbLoader.loadMovie(this.picHolder.attribut es.thmb);
this.thumbHolder.title = this.picHolder.attributes.title;
this.thumbHolder.main = this.picHolder.attributes.main;
this.thumbHolder.onRelease = function() {
loader.loadMovie(this.main);
title_txt.text = this.title;
};
}
};
antonioStarms Guest
-
A scrolling content box inside a flash comp
Hello New to flash - hating it more every passing minute. does anyone know of a way to place a scrolling content box inside another flash... -
MX 2004 Pro Dynamic Scrolling text
Ok, I've looked at almost all the documentation on this scrolling text thing and still nothing works!!!! In my swf I have a textfield that is... -
dynamic text scrolling
Hi, I got some text pulled out of a file using variables and displayed in a dynamic text field which works fine. Is there a way to create a custom... -
Scrolling Dynamic text
I was going through the tutorial in Exploring ... book and thought what if I have more text than the text field can hold? I tried using the... -
Dynamic Scrolling Text
Does anyone know how to create a scrolling banner that displays news dynamically from a DB? Thanks -
BrnstormWilly #2
Re: Need help scrolling dynamic content from XML
You need to switch from using loadMovie to using the MovieClipLoader object.
This object has a listener called "onLoadInit" that allows you to get the size
of your photo when it comes in, but before it appears on stage, so that you can
adjust its placement. Check out the help docs for info on usage.
WL
BrnstormWilly Guest



Reply With Quote

