- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
in the standard UI, when you add a user parameter, there's a drop down for units. At the top of the list is "No Units" - with this option you can create a unitless parameter, and it works.
Unless I'm missing something, there doesn't seem to be a way to create a unitless parameter in the API.
userParams = self.design.userParameters dValIn = adsk.core.ValueInput.createByReal(10.0) dParameter = userParams.add('unitLessParameter',dValIn, self.design.unitsManager.defaultLengthUnits, '')
unitsManager doesn't seem to have the "no Units" option. Am I missing something, or is this an oversight in the API?
Regards
Peter
I'm not an expert, but I know enough to be very, very dangerous.
Life long R&D Engineer (retired after 30+ years in Military Communications, Aerospace Robotics and Transport Automation).
Life long R&D Engineer (retired after 30+ years in Military Communications, Aerospace Robotics and Transport Automation).
Solved! Go to Solution.