- Reading an element in a matrix
Reading an element in a matrix The following code is used to read the value of a matrix element. The name of the matrix, the row and column of the element to read are entered by the user in edit controls (EDT_MatrixName, EDT_ElementRow, EDT_ElementColumn).
// -- Click code on BTN_Read // Declare the variable ResRead is real // Read the element ResRead = MatRead(EDT_MatrixName, EDT_ElementRow, EDT_ElementColumn) // Error? IF MatError(EDT_MatrixName) = 0 THEN Info("The value of the element (row " + EDT_ElementRow + ", "+ ... "column " + EDT_ElementColumn + ") is: " + ResRead) ELSE // Display the error message Error(ErrorInfo(errMessage)) END
This page is also available for…
|
|
|
|