| MATLAB® | ![]() |
#include "matrix.h" bool mxIsChar(const mxArray *pm);
integer*4 mxIsChar(pm) mwPointer pm
Pointer to an mxArray
Logical 1 (true) if pm points to an array having the class mxCHAR_CLASS, and logical 0 (false) otherwise.
Use mxIsChar to determine whether pm points to string mxArray.
In C, calling mxIsChar is equivalent to calling:
mxGetClassID(pm) == mxCHAR_CLASS
In Fortran, calling mxIsChar is equivalent to calling:
mxGetClassName(pm) .eq. 'char'
See phonebook.c and revord.c in the refbook subdirectory of the examples directory.
For additional examples, see mxcreatecharmatrixfromstr.c, mxislogical.c, and mxmalloc.c in the mx subdirectory of the examples directory.
![]() | mxIsCell (C and Fortran) | mxIsClass (C and Fortran) | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |