* Merge winforms framework content to working branch (#14) * Breadcrumb / TOC / Move net5 to net folder (#15) * change path from net5 to net * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Mess with bread/toc * Add .net 5 winforms placeholder article (#16) * added some metadata and adjusted net5 placeholder * corrections * corrections * corrections * Test1 * Swapping landing page vs concept * fix links * Fix links * Fix desc
2.1 KiB
title, ms.date, dev_langs, helpviewer_keywords, ms.assetid
| title | ms.date | dev_langs | helpviewer_keywords | ms.assetid | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Reflect Data Source Updates in Control with BindingSource | 03/30/2017 |
|
|
bd8bd9b2-af8a-4f11-a3d5-54eecbe2400b |
How to: Reflect Data Source Updates in a Windows Forms Control with the BindingSource
When you use data-bound controls, you sometimes have to respond to changes in the data source when the data source does not raise list-changed events. When you use the xref:System.Windows.Forms.BindingSource component to bind your data source to a Windows Forms control, you can notify the control that your data source has changed by calling the xref:System.Windows.Forms.BindingSource.ResetBindings%2A method.
Example
The following code example demonstrates using the xref:System.Windows.Forms.BindingSource.ResetBindings%2A method to notify a bound control about an update in the data source.
[!code-cppSystem.Windows.Forms.DataConnector.ResetBindings#1] [!code-csharpSystem.Windows.Forms.DataConnector.ResetBindings#1] [!code-vbSystem.Windows.Forms.DataConnector.ResetBindings#1]
Compiling the Code
This example requires:
- References to the System, System.Drawing and System.Windows.Forms assemblies.