SetEquation

 Calling Sequence SetEquation(p, idx, eq)

Parameters

 p - handle to a SolidWorks document idx - index of an equation eq - equation to set

Description

 • The SetEquation command sets the equation index idx in the SolidWorks document to the equation specified by eq.

Examples

 > $\mathrm{with}\left(\mathrm{CAD}[\mathrm{SolidWorks}]\right):$
 > $\mathrm{OpenConnection}\left(\right):$
 > $\mathrm{doc}≔\mathrm{OpenDocument}\left("c:/mypart.sldprt"\right):$
 > $\mathrm{GetEquationList}\left(\mathrm{doc}\right)$
 $\left[{""D1@Distance1@myassem.Assembly"=40"}{,}{""D1@Distance2@myassem.Assembly"=4"}\right]$ (1)
 > $\mathrm{SetEquation}\left(\mathrm{doc},0,""D1@Distance1@myassem.Assembly"=30"\right)$
 > $\mathrm{UpdateDocument}\left(\mathrm{doc}\right):$
 > $\mathrm{GetEquationList}\left(\mathrm{doc}\right)$
 $\left[{""D1@Distance1@myassem.Assembly"=30"}{,}{""D1@Distance2@myassem.Assembly"=4"}\right]$ (2)
 > $\mathrm{CloseConnection}\left(\right):$