n = 100;
f = figure;
for i=1:n
  h = uipanel( 'parent', f );
  % h = uicontrol( 'parent', f );
  % pause(0.1)
  delete(h)
end
