Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
538
UltraWinTree BringIntoView is deathslow when using images
posted

Hi all,

I use .NET 1.1, NedAdvantage 2007.1

I have to load 6000 nodes into an ultrawintree, deepest level is 4. All nodes were added using the AddRange method except the first node. Icons are assigned to the node by means of an index from the imagelist. When i call the BringIntoView method after filling the tree, it could take up to 6 seconds before the method completes. When i do not set an image index, the BringIntoView method terminates immediately.

Has anyone experienced this and how do i get arround this problem?

 Regards

 Peter 

 

 

Parents
  • 69832
    Offline posted

    I vaguely remember an issue with the .NET ImageList whereby performance was impacted adversely because something caused the collection's IndexOf method to be called frequently; IndexOf causes a linear search through the collection, which can hit performance significantly. I think the .NET TreeView got around this using some internal code that we of course don't have access to.

    If this is the same issue, the solution is to simply not use the image's index, but rather assign a reference to the image. Also, this had nothing to do with BringIntoView, it was caused by the fact that when we regenerate the UIElements for the control, we have to get a reference to the image in order to draw it. You could verify this by commenting out the call to BringIntoView; even when scrolling the nodes, you should see sluggish performance. If there is any doubt, just log an incident with Developer Support and we will sort it out.

Reply Children