I have been using a treeview control to display ANSI EDI data , but of late I have run into a great number of "really large" files... that is, I am trying to put several hundred thousand items into the tree control.
Needless to say, this can take approximately "forever" to add all those nodes to the tree.
I have been thinking about how to make this faster and had a couple of ideas...
1. Instead of asking the tree control to hold the text of each node, hold the text separately and use style LPSTR_TEXTCALLBACK and just go get the text when Windows asks for it.
2. Load the tree from a separate thread.. allowing the user to work with "what's already been loaded" whilst the balance of the data continue to load.
3. Eschewing the treeview control entirely and painting the visible portion of the tree myself when Windows asks (e.g, on a static control or a proprietary window class window). (The "tree" is just so perfect a presentation).
I'll be playing around with all these methods over the next couple of weeks, but in the meantime if anyone has any suggestions or comments on the above thoughts I'd really appreciate those ideas.
Thanks,
------------------
Michael Mattias
Tal Systems Inc.
Racine WI USA
mailto:[email protected][email protected]</A>
www.talsystems.com
Needless to say, this can take approximately "forever" to add all those nodes to the tree.
I have been thinking about how to make this faster and had a couple of ideas...
1. Instead of asking the tree control to hold the text of each node, hold the text separately and use style LPSTR_TEXTCALLBACK and just go get the text when Windows asks for it.
2. Load the tree from a separate thread.. allowing the user to work with "what's already been loaded" whilst the balance of the data continue to load.
3. Eschewing the treeview control entirely and painting the visible portion of the tree myself when Windows asks (e.g, on a static control or a proprietary window class window). (The "tree" is just so perfect a presentation).
I'll be playing around with all these methods over the next couple of weeks, but in the meantime if anyone has any suggestions or comments on the above thoughts I'd really appreciate those ideas.
Thanks,
------------------
Michael Mattias
Tal Systems Inc.
Racine WI USA
mailto:[email protected][email protected]</A>
www.talsystems.com
Comment