Re: [flexcoders] Issue with Tree in Flex
Thank you steve, I'm using expandTree(); to get the first node expanded on creation of the tree. my requirement is to keep the first node open after creation of the tree, there after it will be handled by the user. thanks and Regards DB valdhor-3 wrote: DB I tried your code and saw the exact issue you describe. Commenting the line: //expandTree(); fixes it. I don't use Tree but I would surmise you are double handling the expand functionality. From what I can see the tree component already implements expand and by adding your own you are causing the problem. Someone else who uses tree more extensively may have a better explanation. HTH. Steve --- In flexcoders@yahoogroups.com, duraibalaji duraibal...@... wrote: Hi flex experts, I'm using tree for a requirement, when we try to open more number of nodes and browse thru the the tree, these are the issues that occur. 1) Tree View goes either Blank or filled with one node name. 2) It hides few nodes. In other words, On expanding more nodes the tree view goes either blank or hides few nodes (sometimes the single node name appears through out the tree view). The following is a sample tree code that i'm trying to use. You can copy paste and try executing this. Thanks in Advance. Regards DB -- View this message in context: http://www.nabble.com/Issue-with-Tree-in-Flex-tp22538899p22558475.html Sent from the FlexCoders mailing list archive at Nabble.com.
RE: [flexcoders] Issue with Tree in Flex
Ok, but do not do that in the labelFunction. Do it after assigning the dataProvider, probably delayed with callLater(). Tracy Spratt, Lariat Services, development services available _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of duraibalaji Sent: Tuesday, March 17, 2009 9:20 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Issue with Tree in Flex Thank you steve, I'm using expandTree(); to get the first node expanded on creation of the tree. my requirement is to keep the first node open after creation of the tree, there after it will be handled by the user. thanks and Regards DB valdhor-3 wrote: DB I tried your code and saw the exact issue you describe. Commenting the line: //expandTree(); fixes it. I don't use Tree but I would surmise you are double handling the expand functionality. From what I can see the tree component already implements expand and by adding your own you are causing the problem. Someone else who uses tree more extensively may have a better explanation. HTH. Steve --- In flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com, duraibalaji duraibal...@... wrote: Hi flex experts, I'm using tree for a requirement, when we try to open more number of nodes and browse thru the the tree, these are the issues that occur. 1) Tree View goes either Blank or filled with one node name. 2) It hides few nodes. In other words, On expanding more nodes the tree view goes either blank or hides few nodes (sometimes the single node name appears through out the tree view). The following is a sample tree code that i'm trying to use. You can copy paste and try executing this. Thanks in Advance. Regards DB -- View this message in context: http://www.nabble. http://www.nabble.com/Issue-with-Tree-in-Flex-tp22538899p22558475.html com/Issue-with-Tree-in-Flex-tp22538899p22558475.html Sent from the FlexCoders mailing list archive at Nabble.com.
RE: Re: [flexcoders] Issue with Tree in Flex
Hi Tracy, yes, you are right, I 've removed it and calling the expandTree from a changewatcher, the function is fine and working as per requirement. i don't see any issues in tree now. Thanks for all giving excellent advices regards DB Tracy Spratt wrote: Yes, a label function should only build the label string, not do anything else, especially manipulate the visual elements of the control it is being used to render. A label function gets called for every visible node in the tree, which changes when you scroll, open a node, etc. No wonder you confused the poor tree! What is the goal of that line? Tracy Spratt, Lariat Services, development services available _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of valdhor Sent: Monday, March 16, 2009 12:15 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: Issue with Tree in Flex DB I tried your code and saw the exact issue you describe. Commenting the line: //expandTree(); fixes it. I don't use Tree but I would surmise you are double handling the expand functionality. From what I can see the tree component already implements expand and by adding your own you are causing the problem. Someone else who uses tree more extensively may have a better explanation. HTH. Steve --- In flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com, duraibalaji duraibal...@... wrote: Hi flex experts, I'm using tree for a requirement, when we try to open more number of nodes and browse thru the the tree, these are the issues that occur. 1) Tree View goes either Blank or filled with one node name. 2) It hides few nodes. In other words, On expanding more nodes the tree view goes either blank or hides few nodes (sometimes the single node name appears through out the tree view). The following is a sample tree code that i'm trying to use. You can copy paste and try executing this. Thanks in Advance. Regards DB -- View this message in context: http://www.nabble.com/Issue-with-Tree-in-Flex-tp22538899p22571253.html Sent from the FlexCoders mailing list archive at Nabble.com.
[flexcoders] Issue with Tree in Flex
Hi flex experts, I'm using tree for a requirement, when we try to open more number of nodes and browse thru the the tree, these are the issues that occur. 1) Tree View goes either Blank or filled with one node name. 2) It hides few nodes. In other words, On expanding more nodes the tree view goes either blank or hides few nodes (sometimes the single node name appears through out the tree view). The following is a sample tree code that i'm trying to use. You can copy paste and try executing this. Thanks in Advance. Regards DB ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.adobe.com/2006/mxml; layout=absolute creationComplete=init() width=100% height=100% mx:Script ![CDATA[ [Bindable] public var TreeXML:XML=null; private function init():void { var strXML:String = new String(node label = 'Country' id='00'node label='Region1' id='1'node label='City1' id='1'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City2' id='2'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City3' id='3'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City4' id='4'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City5' id='5'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City6' id='6'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City7' id='7'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City8' id='8'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City9' id='9'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//node/nodenode label='Region2' id='2'node label='City1' id='1'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City2' id='2'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City3' id='3'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City4' id='4'node label='Retailer1' id='1'/node label='Retailer2' id='2'/node label='Retailer3' id='3'/node label='Retailer4' id='4'/node label='Retailer5' id='5'/node label='Retailer6' id='6'/node label='Retailer7' id='7'/node label='Retailer8' id='8'/node label='Retailer9' id='9'//nodenode label='City5'