Hello all,
Being part of a larger project, I wish to iterate over a bunch of pushbuttons on a Figure Window, and display the iterator number on the Command Window. I have written something like
for iter = 1 : 5 uicontrol('style', 'pushbutton', 'position', [20 iter*30 50 20], 'string', 'Open...', 'callback', 'iter')end
but this gives always
iter = 5
when invoking any of the five pushbuttons. What am I missing here?
Thanks for all the help! Gabriel
Best Answer