Re: GDI leak in DataGridView
- From: "ClayB" <clayb@xxxxxxxxxxxxxx>
- Date: 14 Feb 2007 16:33:23 -0800
In addition to the FreezePainting code mentioned above, here is
another thing you might try. Somehow, call suspendbinding on the
datasource. If you are using a BindingSource, you could try calling
BindingSource.SuspendBinding/ResumeBinding. Another way to do this is
through the CurrencyManager which also has a SuspendBinding/
ResumeBinding methods. To get the CurrencyMaanger, you can use code
like:
CurrencyManager cm = grid.BindingContext[grid.DataSource,
grid.DataMember] as CurrencyManager;
The FreezePainting will suspend the drawing of the control, whereas
the SuspendBinding will avoid the grid reacting to
IBindingList.ListChanged events.
=================
Clay Burch
Syncfusion, Inc.
.
- References:
- Re: GDI leak in DataGridView
- From: ClayB
- Re: GDI leak in DataGridView
- From: ClayB
- Re: GDI leak in DataGridView
- From: ClayB
- Re: GDI leak in DataGridView
- Prev by Date: Re: GDI leak in DataGridView
- Next by Date: RE: listview vertical scrollbar width
- Previous by thread: Re: GDI leak in DataGridView
- Next by thread: RE: listview vertical scrollbar width
- Index(es):