RE: [flexcoders] xml data and drag related questions
Yes the node is called comments. I changed its name to commentary but still all other nodes I can access using {dg.selectedItem.nodeName} I really have no idea why things aren't working. Alex Harui [EMAIL PROTECTED] wrote: Is it really a tag called “comments” or did you use a comments tag !..? What gets displayed in the DG for the comments tag? If the grid items are XML, then the items you get in the drop will be XML and not of type Sport. - From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of g07m5064 Sent: Sunday, September 16, 2007 1:45 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] xml data and drag related questions I have two questions. First, I have the following xml file: ?xml version=1.0 encoding=UTF-8 standalone=yes? contenders xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; contender pos=1 nameLewis Hamilton/name age22/age nationalityEnglish/nationality sportMotorsport/sport commentsEverything seems to come easy for the F1 ace. Hamilton Academical, you might say. Never mind. He's British, very good, and steered his way round a spying row and team turmoil. And can you ever tire (tyre?) of seeing him as a cheeky karting schoolboy...?/comments /contender contender pos=2 nameRicky Hatton/name age29/age nationalityEnglish/nationality sportBoxing/sport commentsTiming is crucial for the Manchester 'Hitman'. And his super fight against Floyd Mayweather could not have been scheduled better./comments /contender /contenders I am buffled by the fact that the comments node is not accessible i.e. I cannot display its contents in a grid though I have no problems with other nodes. I am not sure of the reason. Any ideas? My second question is assuming I wanted to drag a row from the grid into an HBox container with intentions of adding items to an arraycollection so that the dragged items can effectively be diplayed in another grid found in another 'page'. This is my code for the drop function: private function doDragDrop(event:DragEvent):void { var data:Object = event.dragSource.dataForFormat(items) as Sport; //Sport is class draggedData.addItem(data); //draggedData is an instance of ArrayCollection whose contents will be used as dataProvider for the other grid } count++;// The HBox will display the count value of number of dragged items - For ideas on reducing your carbon footprint visit Yahoo! For Good this month.
[flexcoders] xml data and drag related questions
I have two questions. First, I have the following xml file: ?xml version=1.0 encoding=UTF-8 standalone=yes? contenders xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; contender pos=1 nameLewis Hamilton/name age22/age nationalityEnglish/nationality sportMotorsport/sport commentsEverything seems to come easy for the F1 ace. Hamilton Academical, you might say. Never mind. He's British, very good, and steered his way round a spying row and team turmoil. And can you ever tire (tyre?) of seeing him as a cheeky karting schoolboy...?/comments /contender contender pos=2 nameRicky Hatton/name age29/age nationalityEnglish/nationality sportBoxing/sport commentsTiming is crucial for the Manchester 'Hitman'. And his super fight against Floyd Mayweather could not have been scheduled better./comments /contender /contenders I am buffled by the fact that the comments node is not accessible i.e. I cannot display its contents in a grid though I have no problems with other nodes. I am not sure of the reason. Any ideas? My second question is assuming I wanted to drag a row from the grid into an HBox container with intentions of adding items to an arraycollection so that the dragged items can effectively be diplayed in another grid found in another 'page'. This is my code for the drop function: private function doDragDrop(event:DragEvent):void { var data:Object = event.dragSource.dataForFormat(items) as Sport; //Sport is class draggedData.addItem(data); //draggedData is an instance of ArrayCollection whose contents will be used as dataProvider for the other grid } count++;// The HBox will display the count value of number of dragged items
RE: [flexcoders] xml data and drag related questions
Is it really a tag called comments or did you use a comments tag !..? What gets displayed in the DG for the comments tag? If the grid items are XML, then the items you get in the drop will be XML and not of type Sport. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of g07m5064 Sent: Sunday, September 16, 2007 1:45 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] xml data and drag related questions I have two questions. First, I have the following xml file: ?xml version=1.0 encoding=UTF-8 standalone=yes? contenders xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance http://www.w3.org/2001/XMLSchema-instance contender pos=1 nameLewis Hamilton/name age22/age nationalityEnglish/nationality sportMotorsport/sport commentsEverything seems to come easy for the F1 ace. Hamilton Academical, you might say. Never mind. He's British, very good, and steered his way round a spying row and team turmoil. And can you ever tire (tyre?) of seeing him as a cheeky karting schoolboy...?/comments /contender contender pos=2 nameRicky Hatton/name age29/age nationalityEnglish/nationality sportBoxing/sport commentsTiming is crucial for the Manchester 'Hitman'. And his super fight against Floyd Mayweather could not have been scheduled better./comments /contender /contenders I am buffled by the fact that the comments node is not accessible i.e. I cannot display its contents in a grid though I have no problems with other nodes. I am not sure of the reason. Any ideas? My second question is assuming I wanted to drag a row from the grid into an HBox container with intentions of adding items to an arraycollection so that the dragged items can effectively be diplayed in another grid found in another 'page'. This is my code for the drop function: private function doDragDrop(event:DragEvent):void { var data:Object = event.dragSource.dataForFormat(items) as Sport; //Sport is class draggedData.addItem(data); //draggedData is an instance of ArrayCollection whose contents will be used as dataProvider for the other grid } count++;// The HBox will display the count value of number of dragged items