I'm trying to show and hide groups and single items of a PropertyGrid depending on the answers inside the same propertyGrid.
I've seen that a good place to set the visibility of the group is in when the grid is created, in this function:
However, I'm not able to change the visibility at a second time, since this function is not called again later.
If I try to change the visibility of the VisualItem in OnItemFormatting, the items are hidden, but the spaces are not recalculated and the design is messed up.
Also, if I try to change the visibility of an item at the end of OnEdited, OnItemFormatting goes on loop.
Any hint? :)