MFC tree control list generation
-
I am improving an application that is taking forever to load, primarily because each time it loads it initialises a full tree of nearly 100000 items, even though there are only 5 or so keys viewable from the root path. Does the MFC tree control have any sort of support for reading only what is needed, or do I need to hook the open scope(whatever they may be called) functions and code it manually? When I die I'd like to go peacefully in my sleep like my father, not screaming in terror like his passengers!!!
-
I am improving an application that is taking forever to load, primarily because each time it loads it initialises a full tree of nearly 100000 items, even though there are only 5 or so keys viewable from the root path. Does the MFC tree control have any sort of support for reading only what is needed, or do I need to hook the open scope(whatever they may be called) functions and code it manually? When I die I'd like to go peacefully in my sleep like my father, not screaming in terror like his passengers!!!
This[^] will be of some help. Take a look at
TVN_GETDISPINFO
. Another keyword for look up isLPSTR_TEXTCALLBACK
. For more details on how this works take alook at the TVITEM
structure documentation for more details.Look closely at the callback values for Image and Text.
Using this you can create your own virtual tree control.
Nibu thomas Software Developer
-
This[^] will be of some help. Take a look at
TVN_GETDISPINFO
. Another keyword for look up isLPSTR_TEXTCALLBACK
. For more details on how this works take alook at the TVITEM
structure documentation for more details.Look closely at the callback values for Image and Text.
Using this you can create your own virtual tree control.
Nibu thomas Software Developer