Execute
Execute MATLAB command in Automation server
Synopsis
IDL Method Signature
BSTR Execute([in] BSTR command)
Microsoft Visual Basic Client
Execute(command As String) As String
MATLAB Client
result = Execute(h,'command')
Description
result = Execute(h,'command')
executes the MATLAB® statement specified by command
in the MATLAB Automation server attached to h
. To call a function with
arguments, use Feval
.
The server returns output from the command and any MATLAB warning or error messages in result
. If you terminate the
MATLAB command with a semicolon and there are no warnings or error messages,
result
might be empty.
COM functions are available on Microsoft® Windows® systems only.
Examples
Tips
To display output from
Execute
in the client window, specify an output variable,result
.If there is an error, the
Execute
function returns the MATLAB error message with the characters???
prepended to the text.
Version History
Introduced before R2006a