Markus Johansson
Markus Johansson

Reputation: 3773

Who caused size change event?

My application ends up in a resize-loop at certain circumstances. I can set a breakpoint in DataGrid.OnRenderSizeChanged(SizeChangedInfo sizeInfo) but the cause of the change event is unknown. The debugger says [External Code].

Is there a way to find out what causes the size change events?

Upvotes: 0

Views: 215

Answers (1)

Dan Puzey
Dan Puzey

Reputation: 34198

If you attach Snoop (http://snoopwpf.codeplex.com/) to your application, you can monitor events and work out what's first causing your resize.

Also, where it says "[External Code]": if you disable "Just my code" in the debugging options, you'll see the callstack through the .NET framework code, which may give you a clue as to where the loop is coming from.

Upvotes: 2

Related Questions