Returns / sets a single element of the current matrix.
MatrixObject.Item(RowIndex, ColIndex) = Value Value = MatrixObject.Item(RowIndex, ColIndex)
Read / write. A Double value if matrix is real, or a Complex value if matrix is a complex matrix.
This is the default property of the matrix object, so you don't have to refer explicitly to the property when setting or retrieving its value. Any of the following statements are valid.
M.Item(0, 0) = 1.1 a = M.Item(0, 0) ' Item property can be omitted M(0, 0) = 1.1 a = M(0, 0)
Item property is zero based. Upper left most element is MatrixObject.Item(0, 0) and lower right most element is MatrixObject.Item(MatrixObject.Rows - 1, MatrixObject.Cols - 1).
Error 1319 is returned if RowIndex parameter points to an element outside matrix bounds.
Error 1320 is returned if ColIndex parameter points to an element outside matrix bounds.