Closed chancesmith closed 8 months ago
@chancesmith It is more safe to hide the property instead of removing it. It is very likely that we don't check that this property may not exist in our code in Creator. Please use the following code:
const prop = Survey.Serializer.findProperty("survey", "progressBarType");
prop.visible = false;
Thank you, Andrew
@chancesmith,
You can also use the creator.onShowingProperty
event to hide unwanted settings. For more information, please visit the following demo: Hide a Category from the Property Grid.
Should you have any further questions, please feel free to reactivate this thread.
Thanks
Are you requesting a feature, reporting a bug or ask a question?
bug
What is the current behavior?
When removing the survey
progressBarType
property, an error occurs.Uncaught TypeError: Cannot read properties of undefined (reading 'toLowerCase')
What is the expected behavior?
I expect the Progress Bar Type property to be removed from the property grid.
How would you reproduce the current behavior (if this is a bug)?
Call
Serializer.removeProperty("survey", "progressBarType");
Provide the test code and the tested page URL (if applicable)
Tested page URL: https://codepen.io/chancesmith/pen/dyLPdOY
Test code
Specify your