MATLAB: Check “edittext” empty or not

edittext containing value

Hello all.. ^^ I want to ask, how to check an "edittext" containing value or not..?? Thank you.. đŸ™‚

Best Answer

S = get(TheHandle, 'String');
if isempty(S)
disp('no value');
else
disp('value is present');
end
Note, though, that the value that is present might be all blanks or other whitespace.