Message 1 of 3
Bug?: isValueError property no longer working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Looks like the isValueError property on StringValueCommandInput is no longer having the desired effect when set to True from the inputChanged handler (should be that input field turns red and ok button is disabled). Was working before.
Please let me know if I'm off base and there is a way to make this property work as documented.
-Dave
Here's some relevant code from the inputChanged handler...
app = adsk.core.Application.get()
document = app.activeDocument
design = document.products.itemByProductType( 'DesignProductType' )
unitsMgr = design.unitsManager
if changed_input.id == 'strId':
if unitsMgr.isValidExpression(changed_input.value, unitsMgr.defaultLengthUnits):
realValue = unitsMgr.evaluateExpression(changed_input.value, unitsMgr.defaultLengthUnits)
else:
changed_input.isValueError = True