MATLAB: Loop question for listdlg

loop

for aaa = 1:3
cd(rootdir)
d = dir;
str = {d.name};
[s,v] = listdlg('PromptString','Select a file:',...
'SelectionMode','multiple',...
'ListString',str)
matlabdir= get(handles.edit1, 'string')
cd(matlabdir)
end
this is what i have, but for some reason, it does not loop

Best Answer

never mind, i figured out what i did wrong