trashman
03-20-2005, 09:10 PM
howdy!
i've been mucking around with the data components a bit. i've got a fairly simple image gallery going, that uses loadMovie with the image URL's brought in from XML. i load 5 jpg's in to 5 movie clip 'targets' - the 5 URLs are child nodes of a Parent "page" node in the XML.
i have this script on the main timeline to load the first 'Page' of images:
//goto first data set record
_root.XMLdataSet_ds.first();
loadMovie(_root.XMLdataSet_ds.image05,"tn_holder5");
stop();
then i have a button with this, to move the DataSet to the next item/line:
on(click) {
_root.XMLdataSet_ds.next();
}
i had hoped hitting the button would advance the dataset to the next Item (which it does. i put a DataGrid in which is populated from the XML. when i hit the next button, the highlight in the Grid moves to the next line.)
BUT the loaded images do not update when the button is hit. any ideas why this is? perhaps i need to unload the loaded .jpg, then reload the items, but now i'd be looking at 'line 2' of the dataset?? it looks like i got most of the data binding stuff working,i think i'm just missing something basic. any thoughts??
thnaks for any and all help!
i've been mucking around with the data components a bit. i've got a fairly simple image gallery going, that uses loadMovie with the image URL's brought in from XML. i load 5 jpg's in to 5 movie clip 'targets' - the 5 URLs are child nodes of a Parent "page" node in the XML.
i have this script on the main timeline to load the first 'Page' of images:
//goto first data set record
_root.XMLdataSet_ds.first();
loadMovie(_root.XMLdataSet_ds.image05,"tn_holder5");
stop();
then i have a button with this, to move the DataSet to the next item/line:
on(click) {
_root.XMLdataSet_ds.next();
}
i had hoped hitting the button would advance the dataset to the next Item (which it does. i put a DataGrid in which is populated from the XML. when i hit the next button, the highlight in the Grid moves to the next line.)
BUT the loaded images do not update when the button is hit. any ideas why this is? perhaps i need to unload the loaded .jpg, then reload the items, but now i'd be looking at 'line 2' of the dataset?? it looks like i got most of the data binding stuff working,i think i'm just missing something basic. any thoughts??
thnaks for any and all help!