API to Set Dual Units
API to Set Dual Units
(OP)
I know how to toggle Dual Disply of units on and off, but I can't figure out how to set the dual units (i.e. inch/mm, precision, tolerance)
Thanks,
Ken
Thanks,
Ken
When was the last time you drove down the highway without seeing a commercial truck hauling goods?
Download nowINTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS Come Join Us!Are you an
Engineering professional? Join Eng-Tips Forums!
*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail. Posting GuidelinesJobs |
|
RE: API to Set Dual Units
RE: API to Set Dual Units
Regards,
Scott Baugh, CSWP
3DVision Technologies
www.3dvisiontech.com
www.scottjbaugh.com
FAQ731-376
FAQ559-716 - SW Fora Users
RE: API to Set Dual Units
Set values for:
swDetailingLinearDimPrecision - Integer value for precision.
swDetailingLinearTolPrecision - Integer value for precision.
swDetailingAltLinearDimPrecision - Integer value for precision.
swDetailingAltLinearTolPrecision - Integer value for precision.
swDetailingAngularDimPrecision - Integer value for precision.
swDetailingAngularTolPrecision - Integer value for precision.
http://www.EsoxRepublic.com
RE: API to Set Dual Units
Here's a snip of the code I am using, but it doesn't seem to be working:
CODE
'Set to Metric
Part.SetUserPreferenceIntegerValue swUnitsLinear, swMM
Part.SetUserPreferenceToggle swDetailingDualDimensions, True
Part.SetUserPreferenceIntegerValue swDetailingLinearDimPrecision, 2
Part.SetUserPreferenceIntegerValue swDetailingLinearTolPrecision, 2
Part.SetUserPreferenceIntegerValue swDetailingAltLinearDimPrecision, 3
Part.SetUserPreferenceIntegerValue swDetailingAltLinearTolPrecision, 3
swApp.SendMsgToUser "Conversion to Metric made successfully"
Else
'Set to Inch
Part.SetUserPreferenceIntegerValue swUnitsLinear, swINCHES
Part.SetUserPreferenceToggle swDetailingDualDimensions, False
Part.SetUserPreferenceIntegerValue swDetailingLinearDimPrecision, 3
Part.SetUserPreferenceIntegerValue swDetailingLinearTolPrecision, 3
Part.SetUserPreferenceIntegerValue swDetailingAltLinearDimPrecision, 2
Part.SetUserPreferenceIntegerValue swDetailingAltLinearTolPrecision, 2
swApp.SendMsgToUser "Conversion to Imperial made successfully"
End If
None of the "alt" values change. Am I missing something?
Thanks,
Ken
RE: API to Set Dual Units
RE: API to Set Dual Units
RE: API to Set Dual Units
Ken