>
> Hi,
>
> I'm having problemes accessing clicked branches in trees. I tried many
> thing but I keep stumbling on undefined items.
>
> Here are piƩces of my code:
>
A number of pointers for accessing a clicked node on a tree:
Basically between beta 2 and 3 node changed to item.
In Beta 3 nodeOpen changed to itemOpen, the correct way to use is
itemOpen="myOpenCode(event)"
Then your code would look like
import mx.events.*;
function myOpenCode(event:TreeEvent):void {
var mynode:Object = event.item;
itemOpen is fired when the tree node is opened, if the user just
clicked on the label text then the event fired is change, to use:
change="mychangeCode(event)"
function myChangeCode(event:Event):void {
var mynode:Object = event.target.selectedItem;
Hope that helps
Andrew
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
SPONSORED LINKS
Web site design development | Computer software development | Software design and development |
Macromedia flex | Software development best practice |
YAHOO! GROUPS LINKS
- Visit your group "flexcoders" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.