When I change the datasource on a datagrid the entire ui can hang for 30 seconds to a minute if I am debugging my application with visual studio (ie DEBUG is set and the debugger is attached)
Performance is fine if the code is recompiled as release.
Is there a reason for this, can it be resolved - debugging an application is getting really painful.
Its hard to say without more information so I'll just offer some things to try/check.
Have you tried setting vs to break on exceptions (i.e. go into Debug->Exceptions->Common Language Runtime Exceptions and check the option to break on all exceptions or when thrown) to see if you're getting lots of exceptions. Also VS can be slow when the first exception is encountered.
Do you see much activity in the output window at that time?
Do you have anything in the watch window(s) or conditional breakpoints where the evaluation of those is contributing to the slow down?
Does the project have the "Enable the Visual Studio hosting process" checked? That will cause VS to load all assemblies that are referenced up front even if nothing is using them so maybe that is somehow related.
Its really wierd. I though I was able to reproduce it with a sample project but now I've failed to do that.
I've not seen any execeptions and nothing is coming up in the debug output.
This problem happens after loadup and every time the view is refereshed.
I'm bound to the View property of a collectionViewSource and I'm repleacing the Source property of the collectionviewsource with a new datatable.
IsSyncronised with currentItem is turned on if that is any help.
I'm going to add some time checks in the code to make sure its slowing down where I think it is
I am just checking the progress of this issue. Did you manage to reproduce it in an isolated sample or to track what exactly cause the dally. Andrews’s suggests are very good start to look if some of the VS settings are causing the delay.
Sincerely,DimiDeveloper Support Engineer, MCPD Infragistics, Inc.www.infragistics.com/support
No, I'm having real problems reproducing this in a demo project now. When it first started happening I was able to reproduce it in a demo, now I can't
I'm going to find time later in the week to see if I can can completely reproduce the way the big project opeerates in order to find this. I'm guessing its something to do with parent child grid binding
I will follow it with you later, please update me if you manage to reproduce it or you find more information.Thank you.
Sincerely,DimitrinaDeveloper Support Engineer, MCPD Infragistics, Inc.www.infragistics.com/support
I face the same issue of UI freeze for at least 10-20 seconds when I am bind the grid to a datasource first time. After the first bind,the later binds are super-fast. Any explanations?
Thank you for your post. Did you try the suggestions Andrew shared and if yes, is it possible for you to send us an isolated sample project where the issue occurs, so we could be able to investigate this further for you.
Looking forward for your reply.