WPF: Binding updates

Whenever you offer a Cancel Changes command you need to delay updates to the Source until the user Accepts Changes e.g. by clicking OK or Save.

Although WPF's two way bindings update the source immediately you can delay the update by adding UpdateSourceTrigger=Explicit to your binding expression.

{Binding Path=Text, UpdateSourceTrigger=Explicit}


The Source won't be updated until you call BindingExpression.UpdateSource.

Comments

jizhang said…
Hi, Jan
The comment has nothing to do with the post.
As you reported a bug in MSDN:http://lab.msdn.microsoft.com/ProductFeedback/viewfeedback.aspx?feedbackid=c466047a-f10b-491e-8198-67cfe7d59e43
, could you please try it again in Beta2? I think the bug is fixed, but we don't have the exact config as yours. Please help to verify it.

Thanks,
Ji_MSFTE

Popular posts from this blog

Custom Chrome in WPF

InstallShield Applications on Vista 5270

Capture WebCam with WinForms2