<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx</link><description>Intro Previously I did a post on the “Control Local Values bug” and how a subtle bug can be introduced when setting dependency properties of controls to local values. In WPF 4.0 (dev10), a mechanism was added to the property engine to solve this problem.</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Vincent Sibal's Blog : The Control Local Values Bug!</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9633882</link><pubDate>Thu, 21 May 2009 18:20:46 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9633882</guid><dc:creator>Vincent Sibal's Blog : The Control Local Values Bug!</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/vinsibal/archive/2009/03/24/the-control-local-values-bug.aspx"&gt;http://blogs.msdn.com/vinsibal/archive/2009/03/24/the-control-local-values-bug.aspx&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9702449</link><pubDate>Sat, 06 Jun 2009 05:30:16 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9702449</guid><dc:creator>PaulF</dc:creator><description>&lt;p&gt;Please don't confuse lack of comments with lack of interest in what you are posting. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;That is a pretty easy thing to do.&lt;/p&gt;
&lt;p&gt;This is one of my favorite msdn blogs, but...., I don't really have anything to add to what you said in this post or others aside from please keep it up.&lt;/p&gt;
&lt;p&gt;Great work keeping all of us developers informed on what is going on at Microsoft.&lt;/p&gt;
&lt;p&gt;Also, I am very happy to see Microsoft fixing issues like this.&lt;/p&gt;</description></item><item><title>re: The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9702836</link><pubDate>Sat, 06 Jun 2009 17:25:03 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9702836</guid><dc:creator>vinsibal</dc:creator><description>&lt;p&gt;Thanks a lot Paul!&lt;/p&gt;
</description></item><item><title>interest</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9734220</link><pubDate>Fri, 12 Jun 2009 16:02:17 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9734220</guid><dc:creator>Rune</dc:creator><description>&lt;p&gt;I just discovered this blog. I've bookmarked it for future refernce and I agree with what Paul said.&lt;/p&gt;
&lt;p&gt;(I came here because I'm trying to discover how to enable deferred scrolling in the datagrid)&lt;/p&gt;</description></item><item><title>re: The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9735469</link><pubDate>Fri, 12 Jun 2009 18:39:07 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9735469</guid><dc:creator>vinsibal</dc:creator><description>&lt;p&gt;Rune, &lt;/p&gt;
&lt;p&gt;See this post, &lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/vinsibal/archive/2008/05/22/wpf-3-5-sp1-feature-non-live-scrolling.aspx"&gt;http://blogs.msdn.com/vinsibal/archive/2008/05/22/wpf-3-5-sp1-feature-non-live-scrolling.aspx&lt;/a&gt;.&lt;/p&gt;
</description></item><item><title>re: The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9738892</link><pubDate>Fri, 12 Jun 2009 23:41:23 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9738892</guid><dc:creator>Fahad</dc:creator><description>&lt;p&gt;This only solves if we use .NET 4.0 beta (or future versions), but how do we solve it in .NET 3.5 FW, this seems to be rather trivial that I do not wish to upgrade to VS2010 yet, then how do i do it? Do we simply reset the BindingExpression?&lt;/p&gt;
&lt;p&gt;var be = tb.GetBindingExpression(TextBox.TextProperty);&lt;/p&gt;
&lt;p&gt;// make my changes in internally&lt;/p&gt;
&lt;p&gt;// reset the BindingExpression&lt;/p&gt;
&lt;p&gt;tb.SetBinding(TextBox.TextProperty, be)&lt;/p&gt;
&lt;p&gt;I just thought of this idea, What do you think about it?&lt;/p&gt;</description></item><item><title>re: The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9739937</link><pubDate>Sat, 13 Jun 2009 01:24:49 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9739937</guid><dc:creator>vinsibal</dc:creator><description>&lt;p&gt;Fahad,&lt;/p&gt;
&lt;p&gt;The solution you propose make work for a simple problem but it does not scale for many of the common scenarios. &amp;nbsp;Take the DatePicker example that I talk about in the previous blog post, &lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/vinsibal/archive/2009/03/24/the-control-local-values-bug.aspx"&gt;http://blogs.msdn.com/vinsibal/archive/2009/03/24/the-control-local-values-bug.aspx&lt;/a&gt;. &amp;nbsp;In OnIsDropDownChanged a member, _popUp.IsOpen is set to a local value. &amp;nbsp;How would you undo that? &amp;nbsp;From the outside you need to get access to _popUp which may or may not be possible and you need to know the kind of expression and ValueSource on IsOpen prior to it being set to a local value. &amp;nbsp;If you knew exactly where this would happen in code and had access to everything then it may work. &amp;nbsp;Since you don't have access to a lot of the Control specific implementation, it makes it impossible to work around this issue. &amp;nbsp;So unfortunately, there is not work around this issue in pre 4.0 bits.&lt;/p&gt;
</description></item><item><title>re: The Control Local Values Bug Solution and new WPF 4.0 related APIs</title><link>http://blogs.msdn.com/vinsibal/archive/2009/05/21/the-control-local-values-bug-solution-and-new-wpf-4-0-related-apis.aspx#9745682</link><pubDate>Sat, 13 Jun 2009 19:49:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9745682</guid><dc:creator>Fahad</dc:creator><description>&lt;p&gt;Thanks for your views Vincent, I agree with your point!!!&lt;/p&gt;</description></item></channel></rss>