flash data integration:
I have an XML content (txt and images) wich comes respectivly on a Txt_field variable and MovieClip. With no problem, I have the content brought and showed, but my problem is that the content of the text and images is to long than the height of my clips. Pliiiz Help Urgent ! How can I set the max height showed and scroll it by th way ? :confused;
hi tkitek can u just paste the xml here
Thanks for your reply ! Well, here you have the action script for filling the xml, and the xml structure... Hope that you give a flexible solution... thanks a lot. Action script-------------------------------------------- portfolioInfo = new XML(); portfolioInfo.ignoreWhite = true; portfolioInfo.onLoad = function(){ portfolioTag = this.firstChild; trace( count = portfolioTag.childNodes.length); for (child = 0; child < count; child++){ currentPicture = portfolioTag.childNodes[child]; currentThumb = menu_mc.createEmptyMovieClip("thumbnail"+child,child); currentThumb._y = child *20; image = currentThumb.createEmptyMovieClip("thumbnail_image",0); image.loadMovie(currentPicture.attributes.THUMB); currentThumb.NAME = currentPicture.attributes.NAME; currentThumb.IMAGE = currentPicture.attributes.IMAGE; currentThumb.TEXT = currentPicture.attributes.TEXT; currentThumb.onRollOver = currentThumb.onDragOver = function(){ showName_txt.text = this.NAME; } currentThumb.onRollOut = currentThumb.onDragOut = function(){ showName_txt.text = ""; } currentThumb.onPress = currentThumb.onDragOver = function(){ image_mc.loadMovie(this.IMAGE); mcxml.info_txt.text = "Loading..."; // load the text into this timeline: mcxml.loadVariables(this.TEXT); } } } portfolioInfo.load("portfolio_config.xml"); stop(); ------------------------------------------------------------------------------ xml file : <PORTFOLIO> <PICTURE NAME="My Disk" THUMB="media/menu/image1.jpg" TEXT="content/description1.txt" IMAGE="media/image1.jpg"/> <PICTURE NAME="My Disk" THUMB="media/menu/image2.jpg" TEXT="content/description2.txt" IMAGE="media/image2.jpg"/> <PICTURE NAME="My Disk" THUMB="media/menu/image3.jpg" TEXT="content/description3.txt" IMAGE="media/image3.jpg"/> <PICTURE NAME="My Disk" THUMB="media/menu/image4.jpg" TEXT="content/description4.txt" IMAGE="media/image4.jpg"/> <PICTURE NAME="My Disk" THUMB="media/menu/image5.jpg" TEXT="content/description5.txt" IMAGE="media/image5.jpg"/> <PICTURE NAME="My Disk" THUMB="media/menu/image6.jpg" TEXT="content/description6.txt" IMAGE="media/image6.jpg"/> </PORTFOLIO>
So what i want to do is scrolling the entire content of menu_mc : currentThumb = menu_mc.createEmptyMovieClip("thumbnail"+child,child); currentThumb._y = child *20; Is there a nice way to do it ?
Don't see what you're looking for? Try a search.
|