8.1.21.22 OriginObject::SetNumProp
It is recommended that you switch to the originpro package. PyOrigin is primarily for users who need to work with Origin version prior to 2021. |
Description
Set object property via LabTalk property name
Syntax
SetNumProp(strVarName, dVal)
Parameters
- strVarName
- Object property name
- dVal
- variable value
Return
Returns 1 if lpcszVarName is a valid name and 0 if it is not. -1 if error occurs
Examples
EX1
import PyOrigin #assumes the active graph has a line object gl = PyOrigin.ActiveLayer() line=gl.GraphObjects('Line') print('color=',line.GetNumProp('color')) line.SetNumProp('color', 2)