I have spent so much time on this, I really need a helping hand. This group has been wonderful to me, I am asking for a little more help than what others are asking for. I was wondering if someone could create an example of the node being dropped (label that is) and the node being dropped into.
public function DoThis():void { trace('I was called'); } Thanks for all the help, timgerr --- In flexcoders@yahoogroups.com, "timgerr" <[EMAIL PROTECTED]> wrote: > > In a drag and drop tree I was wondering how to get the name of the > node being dropped and how to get the name of the node that it was > dropped into? Here is what I have so far, > <?xml version="1.0"?> > <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"> > > <!-- Here is the HTTP Request --> > <mx:HTTPService id="xmlLoader" > url="http://127.0.0.1/try/xml/xml_v7.php" resultFormat="e4x" > contentType="application/xml" > result="xmlReturned(event)" /> > <mx:Canvas xmlns:mx="http://www.adobe.com/2006/mxml" width="400" > height="300" left="20" top="10"> > > <mx:Script> > <![CDATA[ > import mx.collections.XMLListCollection; > [Bindable] > private var xmlValue:XMLListCollection; > private function xmlReturned(event:Event):void > { > xmlValue = new XMLListCollection(new > XMLList(xmlLoader.lastResult)); > } > > public function DoThis():void > { > trace('I was called'); > } > ]]> > > > </mx:Script> > > <mx:Button click="xmlLoader.send()" label="get XML"/> > <mx:Tree dataProvider="{xmlValue}" y="100" labelField="@label" > width="300" showRoot="true" > dragEnabled="true" dropEnabled="true" dragMoveEnabled="true" > dragComplete="DoThis()" > /> > </mx:Canvas> > </mx:Application> > > I do not know what to put for the DoThis function. > Thanks for the help, > timgerr >