Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Tree control that can handle more than 65000 items?
Message
From
07/02/2002 11:38:33
 
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00612390
Message ID:
00616686
Views:
18
Thanks for the information. I actually ended up going with Bela Bodec's FolderTree. It's quite a nice control and doesn't have the limitation because he uses a method to access the nodes instead of an array. He's also gone out of his way to help me get it working in my app. I'd reccommed taking a look at his controls to anyone looking for the functionality he provides.

Thanks,

Michelle


>Michelle,
>Go ahead and do this. There isn't a limit to the number of nodes with the standard treeview control that I could. I created one with 65538 nodes.
>
>However, the limit that others have posted about on this thread does exist with using either the Count property of the Nodes collection or the Index property of the Node itself. As posted, both are 16-bit integers.
>
>When you get to a number larger than the range for a 16-bit integer (0xFFFF or 65535), those properties start reporting from 0 again. Ex.
>? Treeview.Nodes('Node 65536').Index  && reports 0
>? Treeview.Nodes('Node 65537').Index  && reports 1
>? Treeview.Nodes('Node 65538').Index  && reports 2
>
>Using MSKB#Q182231 as a guide, you can get the real count using the following code:
>declare integer SendMessage in win32api integer, integer, integer, integer
>lnCount = SendMessage(Treeview.Hwnd,0x1105,0,0)
>
>If you always use the variant index to access the node, I believe you can have as many as memory allows. The variant index is either the same as the text displayed on the node or it is some other unique string passed to the Add method of the Nodes collection to identify the node.
>
>There is also a problem with the scroll bar when you have too many Nodes. It doesn't behave correctly.
>
>HTH.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform