I simply want to determine the number of files that were selected with the uigetfile function.
size(filename) doesn't work.
The size function returns 1 2 when there are two files and 1 129 when there is a single file. I assume that uigetfile returns an array of strings when there are multiple files and a cell array when there is just one file selected.
Why does MATLAB do this, and how do I fix it?
I have tried variations of iscell, iscellstr, ischar to determine what data type of the single-file filename.
I have tried various ways of concatenation including sprintf,char,str, …
Related complaint: The MATLAB documentation doesn't list uigetfile under Data and File Management. You have to hunt it down or already know what it is called.
Best Answer