<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Fixing a slow scrolling DataGridView</title>
	<atom:link href="http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/feed" rel="self" type="application/rss+xml" />
	<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview</link>
	<description>Lean IT-solutions in .NET/C#</description>
	<lastBuildDate>Thu, 17 May 2012 14:52:35 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
	<item>
		<title>By: Florian</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-27114</link>
		<dc:creator>Florian</dc:creator>
		<pubDate>Fri, 13 Apr 2012 13:10:44 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-27114</guid>
		<description>Thanks for your solution using extension methods!

However I found that I had to enable double buffering for all controls in my application, just enabling it for the DataGridView was not sufficient.

What I did was this:

Change your extension method to work on Controls:
 public static class ExtensionMethods
    {

        public static void DoubleBuffered(this Control control, bool setting)
        {
            Type dgvType = control.GetType();
            PropertyInfo pi = dgvType.GetProperty(&quot;DoubleBuffered&quot;, BindingFlags.Instance &#124; BindingFlags.NonPublic);
            pi.SetValue(control, setting, null);
        }
}

And call it for all controls in my app in the constructor of the main program: DoubleBuffer(this):

    protected void DoubleBuffer(Control control)
    {
        control.DoubleBuffered(true);
        foreach (Control c in control.Controls) { DoubleBuffer(c); }
    }</description>
		<content:encoded><![CDATA[<p>Thanks for your solution using extension methods!</p>
<p>However I found that I had to enable double buffering for all controls in my application, just enabling it for the DataGridView was not sufficient.</p>
<p>What I did was this:</p>
<p>Change your extension method to work on Controls:<br />
 public static class ExtensionMethods<br />
    {</p>
<p>        public static void DoubleBuffered(this Control control, bool setting)<br />
        {<br />
            Type dgvType = control.GetType();<br />
            PropertyInfo pi = dgvType.GetProperty(&#8220;DoubleBuffered&#8221;, BindingFlags.Instance | BindingFlags.NonPublic);<br />
            pi.SetValue(control, setting, null);<br />
        }<br />
}</p>
<p>And call it for all controls in my app in the constructor of the main program: DoubleBuffer(this):</p>
<p>    protected void DoubleBuffer(Control control)<br />
    {<br />
        control.DoubleBuffered(true);<br />
        foreach (Control c in control.Controls) { DoubleBuffer(c); }<br />
    }</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Aryan</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-26516</link>
		<dc:creator>Aryan</dc:creator>
		<pubDate>Sat, 31 Mar 2012 05:28:19 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-26516</guid>
		<description>Wonderful.</description>
		<content:encoded><![CDATA[<p>Wonderful.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Komala</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-24931</link>
		<dc:creator>Komala</dc:creator>
		<pubDate>Sun, 19 Feb 2012 08:55:40 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-24931</guid>
		<description>Thank you :)</description>
		<content:encoded><![CDATA[<p>Thank you <img src='http://bitmatic.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kevin</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-22445</link>
		<dc:creator>Kevin</dc:creator>
		<pubDate>Wed, 21 Dec 2011 16:12:02 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-22445</guid>
		<description>AMAZING!!!</description>
		<content:encoded><![CDATA[<p>AMAZING!!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Riki</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-22140</link>
		<dc:creator>Riki</dc:creator>
		<pubDate>Thu, 15 Dec 2011 10:58:27 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-22140</guid>
		<description>Thank you a lot!
Grazie mille!
Riki</description>
		<content:encoded><![CDATA[<p>Thank you a lot!<br />
Grazie mille!<br />
Riki</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alireza</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-21703</link>
		<dc:creator>Alireza</dc:creator>
		<pubDate>Tue, 06 Dec 2011 13:14:28 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-21703</guid>
		<description>Andrew,

Thank you very much
You really saved me 

good luck</description>
		<content:encoded><![CDATA[<p>Andrew,</p>
<p>Thank you very much<br />
You really saved me </p>
<p>good luck</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: just3fun</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-19667</link>
		<dc:creator>just3fun</dc:creator>
		<pubDate>Sat, 15 Oct 2011 20:04:52 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-19667</guid>
		<description>Andrew, your solution is great! Thank you very much!</description>
		<content:encoded><![CDATA[<p>Andrew, your solution is great! Thank you very much!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vibz</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-17526</link>
		<dc:creator>Vibz</dc:creator>
		<pubDate>Tue, 06 Sep 2011 14:23:47 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-17526</guid>
		<description>Thanks a lot... It worked freaking awesome...

Thanking you million times
VIbz</description>
		<content:encoded><![CDATA[<p>Thanks a lot&#8230; It worked freaking awesome&#8230;</p>
<p>Thanking you million times<br />
VIbz</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-16921</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Wed, 24 Aug 2011 14:02:42 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-16921</guid>
		<description>typeof(DataGridView).InvokeMember(&quot;DoubleBuffered&quot;, BindingFlags.NonPublic &#124; BindingFlags.Instance &#124; BindingFlags.SetProperty, null, my_dgv_ctrl_, new object[] { true });</description>
		<content:encoded><![CDATA[<p>typeof(DataGridView).InvokeMember(&#8220;DoubleBuffered&#8221;, BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.SetProperty, null, my_dgv_ctrl_, new object[] { true });</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John</title>
		<link>http://bitmatic.com/c/fixing-a-slow-scrolling-datagridview/comment-page-1#comment-14333</link>
		<dc:creator>John</dc:creator>
		<pubDate>Thu, 07 Jul 2011 21:17:28 +0000</pubDate>
		<guid isPermaLink="false">http://bitmatic.com/?p=476#comment-14333</guid>
		<description>Such a quick and simple solution!!!!! I love you!!!!!!!!</description>
		<content:encoded><![CDATA[<p>Such a quick and simple solution!!!!! I love you!!!!!!!!</p>
]]></content:encoded>
	</item>
</channel>
</rss>

