Hiding some fields in propertygrid

Grids for WPF Forum

The latest build of this product (v24.1.2) was released 1 month ago, which was before this thread was created.
Posted 1 month ago by Ivan Menshikov
Version: 21.1.2


It is possible to programmatically hide any fields except fields with the list type List<MyItem>

public class MyItem: ObservableObjectBase {..

There is a solution?

Comments (1)

Posted 1 month ago by Actipro Software Support - Cleveland, OH, USA


There are filtering features that you can use to narrow down the properties that are displayed.  Our "Filters" QuickStart shows an example of that.

You can also go lower-level than that and create a data factory class that inherits TypeDescriptorFactory and set an instance of it to the PropertyGrid.DataFactory property.  The custom class can override the GetPropertyModels method and remove any properties from the base method's results that don't meet the criteria you require.

Either of those kinds of features should work.

Actipro Software Support

Add Comment

Please log in to a validated account to post comments.