hey, its my first time actually posting a thread on this site. im making my own streaming mp3 player in flash. im using a playlist that is in xml. i have it working, but i was wanting to know if i could acquire some help in getting it to go to the next song, when the first one is done. ive tried everything. im probably just a horrible flash programmer. ill provide an attachment for my fla file and my code. id appreciate any help. thanks in advance.
var index = 0;
XMLRaw = new XML();
XMLSource = "[http://home.comcast.net/~urtalkinstupid/song.xml](http://home.comcast.net/~urtalkinstupid/song.xml)"
XMLRaw.ignoreWhite = "true"
Songs = new Array();
XMLRaw.load(XMLSource);
XMLRaw.onLoad = function(success){
if(success){
load_txt.text = "Loaded " +XMLSource+ " successfully."
allNodes = this.firstChild.childNodes
for(j = 0; j<allNodes.length; j++){
Songs.push({title:allNodes[j].attributes.title,artist:allNodes[j].attributes.artist,url:allNodes[j].attributes.url});
}
}
else{
load_txt.text = "Failed to load " +XMLSource+ " successfully."
}
showinfo();
}
function showinfo():Void{
sound = new Sound();
sound.loadSound(Songs[index].url,true);
load_txt.text = index+1 + ". " + Songs[index].title + " - " + Songs[index].artist
}