fieldnames
Returns field names of a structure or an handle.
📝Syntax
names = fieldnames(st)
names = fieldnames(h)
names = fieldnames(h, '-full')
📥Input Arguments
Parameter Description
st a structure
h a handle object
📤Output Arguments
Parameter Description
names a cell of strings
📄Description

names = fieldnames(st) returns a cell of strings with the names of the fields in the input structure.

names = fieldnames(h) returns a cell of strings with the names of the properties in the handle (without hidden).

names = fieldnames(h, '-full') returns a cell of strings with the names of the all properties in the handle.

💡Examples
fieldnames(dir())
🔗See Also
getfield
🕔Version History
Version Description
1.0.0 initial version
Edit this page on GitHub