Comments are available to members only. Sign up or Log in to view these comments.
Main Topics
Browse All TopicsHey All,
First let me start by saying I am new to the list component. What I am trying to do is to use a List component in Flash to create a "menu" that is driven by XML data. I want to use the menu to load image files into a blank instance and then have that instance look to see if there are more than one nodes available for an image. If there is more than one then have it display thumbnails of each extra node. I have an idea on how to load the thumbnails, but not real sure on how to get the empty instance to know if there are more nodes referring to an image. Currently I have a list component on the screen, an empty movie clip, and this is what I have so far code (I know, I know pretty basic):
Flash -
import mx.utils.Delegate;
import mx.controls.List;
//************************
var listData:Array = new Array();
var myList_xml:XML;
var myList_ls:List;
//************************
_global.style.setStyle("co
_global.style.setStyle("th
_global.style.setStyle("fo
_global.style.setStyle("fo
_global.style.setStyle("em
myList_ls.rowHeight = 16;
myList_ls.rowCount = 20;
songList_ln.selectable = false;
myList_ls.multipleSelectio
myList_ls.setStyle("altern
//************************
myList_ls.addEventListener
//************************
function doPlay(eventSrc:Object):Vo
_root.dZ.loadMovie(eventSr
}
//************************
myList_xml = new XML();
myList_xml.ignoreWhite = true;
myList_xml.onLoad = Delegate.create(this, myListLoaded);
//************************
function myListLoaded():Void {
var mainNode:XMLNode = this.myList_xml.firstChild
this.myList_ls.dataProvide
var resourceCount:Number = mainNode.childNodes.length
for (var i = 0; i<resourceCount; i++) {
listData.addItem({label:i+
}
//myList_ls.selectedIndex = i;
myList_ls.dispatchEvent({t
}
myList_xml.load("helpXML/s
In XML -
<?xml version="1.0" encoding="UTF-8"?>
<list>
<item url="StimProcessMaps/test/
</list>
I think the XML should look something like this:
<?xml version="1.0" encoding="UTF-8"?>
<list>
<Item title="Stim 100"
<subItem url=myImages/myImageFile1.
<subItem url=myImages/myImageFile2.
<subItem url=myImages/myImageFile3.
</item>
</list>
Any information will be greatly appreciated.
-Frankie
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Business Accounts
Answer for Membership
by: blue-geniePosted on 2008-07-29 at 07:46:19ID: 22111958
Comments are available to members only. Sign up or Log in to view these comments.