Tag: TypeDescriptor

Two-way data-binding to Dynamic Object

Dynamic Object Two Way Data Binding

To create a Dynamic Object which you can use for two-way data-binding to Windows Forms control, you should derive from DynamicObject and also implement ICustomTypeDescriptor and INotifyPropertyChanged interface. DynamicObject: Deriving from DynamicObject provides a solution for specifying dynamic…

Read More »

Make a Property Read-Only in PropertyGrid

Sometimes you want to make a property read-only in PropertyGrid based on some criteria at run-time. For example, let’s suppose you have a SampleClass containing two properties, Editable and StringProperty and you want to make StringProperty read-only if…

Read More »