engGetVariable (Fortran) - Copy variable from MATLAB engine workspace - MATLAB (original) (raw)

Main Content

Copy variable from MATLAB engine workspace

Fortran Syntax

#include "engine.h" mwPointer engGetVariable(ep, name) mwPointer ep character*(*) name

Description

engGetVariable reads the named mxArray from the MATLABĀ® engine session associated with ep. Returns0 if successful and 1 if an error occurs.

The limit for the size of data transferred is 2 GB.

Use mxDestroyArray to destroy the mxArray created by this routine when you are finished with it.

Input Arguments

expand all

Pointer to engine, specified as mwPointer.

Name of mxArray to get from the MATLAB workspace, specified as character*(*).

Pointer to mxArray, specified as mwPointer.

Output Arguments

expand all

Pointer to a newly allocated mxArray structure, returned asmwPointer. Returns NULL if the attempt fails.engGetVariable fails if the named variable does not exist.

Version History

Introduced before R2006a