Description
Arithmetic binary operator to assign values to this McObject, leaving the result in this McObject.
-
Return Type
-
A McObject object.
-
Syntax
-
object.OpSelfAssign (RightOperand)
The OpSelfAssign Method syntax has these parts: |
| object | An expression evaluating to an object of type McObject. | | RightOperand | Required. A Variant value. Right operand. May be a scalar or array of any numeric type. It may also be an McObject instance of a numeric type.
| Remarks
Values from the VARIANT varRightOperand are assigned to replace the values of this McObject, and the result is left in this McObject and returned.
OpSelfAssign differs from OpBareAssign in that the shape (i.e., number and size of dimensions) of this assigned to McObject is not changed by the assignment. Selected elements of an McObject may be assigned to by assigning to the SelectedValues property
If the shape of varRightOperand differs from this McObject, then elements from the varRightOperand are associated with elements from from this McObject in order, irrespective of number of dimensions or sizes of dimensions. If the vector length of varRightOperand is less than that of this McObject, the right operand is re-used as often as necessary.
Exceptions
Operands must be scalars or arrays of some numeric type. Operands may be arrays of VARIANT, but if they are, all elements must be of the same arithmetic type. E.g., Array( 1, 2) is OK, but Array( 1.5, 2) is not legal.
|