Calling Sequence GetDimensionUnit(p, d)

Parameters

 p - handle to a SolidWorks parts file d - name of a dimension

Description

 • The GetDimensionUnit command returns the unit associated with dimension d in the Solidworks file p.

Examples

 > $\mathrm{with}\left(\mathrm{CAD}[\mathrm{SolidWorks}]\right):$
 > $\mathrm{OpenConnection}\left(\right):$
 > $\mathrm{doc}:=\mathrm{OpenDocument}\left("c:/mypart.sldprt"\right)$
 ${\mathrm{doc}}{:=}{0}$ (1)
 > $\mathrm{doc}:=\mathrm{GetDimensionUnit}\left(\mathrm{doc},"D1@Sketch1@mypart.Part"\right)$
 ${\mathrm{Units:-Unit}}{}\left({'}{\mathrm{mm}}{'}\right)$ (2)
 > $\mathrm{doc}:=\mathrm{CloseDocument}\left(\mathrm{doc}\right)$
 > $\mathrm{CloseConnection}\left(\right):$