Solids Builder - Define Variable
Define Variable - creates a local variable, which only exists inside the Constructor, that is, it is not visible in the device properties:
The Define Variable activity has the following properties:
-
Name - variable name
It will be the name of the activity too
You must respect the naming rules
-
Visible Object - when the variable is a geometry (point, line, solid) it may or may not be drawn in the preview
-
Variable Type
-
Double - real number
-
Int32 - integer (32 bits)
-
String - any text
-
Boolean - true/false
-
GeometryPoint - a point recognizable by the Constructor
-
GeometryVector - a Constructor recognizable vector
-
GeometryPLine - a Constructor recognizable polyline
-
GeometryCurve - a curve (line, arc...) recognizable by the Constructor
-
GeometrySolid - a solid recognizable by the Constructor
-
Value - Expression to be evaluated that results in an object of the type specified in 'Variable Type'
Any value, Visual Basic expression that is evaluated for the informed type, examples:
-
Double: 0.5 (the decimal separator is the dot (.))
-
Int32: 54
-
String: "TEXT"
-
VB Expressions:
-
Width + Wall
Assuming they are two variables or parameters
-
Line.StartPoint
assuming that Line is an GeometryCurve
-
Math.Cos(Angle)
Assuming that Angle is a variable that contains an angle given in radians
-
True
Assuming the type is a Boolean
-
A*X^2+B*X*C
Equations must be well written!
(the above equation is different from: A*x² + B*x + C)