Hello, is there a recomended way how to make content of ObjectPropertiesPages dynamic?
My problem is, that content depends on selected object’s custom type. In one case I want to display section A and in other cases I want to display sections A and B.
Because I don’t know the type during initialisation, I hoped to reuse the holder, clear it and add sections needed when new object is selected. I also tryed to create all the entities again but without success. The section is either empty or doesn’t get updated.
Are there some rules to follow or examples to look at?
I’m a little confused by your question. Your page should override
ObjectPropertiesPage.UpdatePage, which is called on the active page after the selected objects list has changed to notify the page to initialize its content to reflect the new object list.
Or am I missing something?
Exactly as you say. My problem came in next step.
I wanted to display section A for one type of objects and sections A + B in rest of the cases.
Because I knew that section A will be needed in both cases, I created just one instance ant tried to reuse it - which is apparently is not possible. After creating separated instances for all the cases I need everything works fine.