Progressbar

a very simple progress bar; it is going to be a flexible one.
678 Downloads
Updated 3 May 2010

View License

it is very straightforward to use this progress bar; first initialize it by calling

prgHandle = prgbar('UserData', steps);

in which 'steps' is the number of turns takes to complete the progress bar. At the moment there are two buttons on it; one to pause/continue functionality and the other other to terminate the computation; the later should be controlled by the user like example.
After initializing in every turn of the loop one can check to see if the bar is alive or not(like the example); in case that the bar is closed, the desired operation can be done.

if ~ishandle(prgHandle)
msgbox('message');
return;
end

in every turn bar should be updated (in the other words it should progress), which can easily be done by calling:

prgbar('goahead');

finally bar can be closed after completing simply by calling

close(prgHandle)

Cite As

Sadegh Bakhtiarzadeh (2024). Progressbar (https://www.mathworks.com/matlabcentral/fileexchange/27461-progressbar), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2010a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Dialog Boxes in Help Center and MATLAB Answers

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.0.0.0