Unable to make enum property to work in PropertyGrid

Grids for WPF Forum

Posted 3 months ago by BIMMATE - CEO, BIMMATE tecnología BIM para la arquitectura y la i
Version: 24.1.3
Avatar

Hello

I am using the WPF PrpertyGrid control and I am unable to make enum properties to work as expected.

In my interface, once of those enum properties is defined as this:

[Browsable(true), ReadOnly(false)]
[Display(
Description = nameof(Resources.UnitOfMeasurement),
GroupName = nameof(Resources.Identification),
Name = nameof(Resources.Unit),
ResourceType = typeof(Resources))]
[NotifyParentProperty(true)]
ConceptUnits Unit { get; }

Although the property only has a getter in the interface, it is marked as ReadOnly(false) because of I am using dynamic properties in runtime and there is a wrapper object handling the properties of the selected object

That wrapper is in charge of calling the proper method to set a new value for the property as it cannot be done directly in the setter because several design patterns implemented in my solution

The problem I face is that ComboBoxes cannot be opened, so I cannot choose a different value. However, if I change the value through the keyboard, it works fine (property is updated and the appropiate method is called to set the new value for the property)

What can be causing the ComboBox not to open on user click?

Comments (1)

Posted 3 months ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hello,

Since you are doing some customized things here via dynamic properties, it's difficult for us to say what is going on without a simple sample to debug with.  Could you throw together a new simple WPF sample project that shows the issue and send that to our support address?  Reference this thread in your email and be sure to exclude the bin/obj folders from the .zip you send so it doesn't get spam blocked.  Then we will debug with that to see why the popup isn't working.  Thanks!


Actipro Software Support

The latest build of this product (v24.1.4) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.