I have created MatLab GUI and it execute matlab script by clicking button on GUI.
now I want method for showing time consuming for run of that script
following code shows how I did that so far
function pushbutton1_Callback(hObject, eventdata, handles)% hObject handle to pushbutton1 (see GCBO)
run('resizeingDONTDELETE.m');end
I find a code for show wait bar but it is not worked!!!!
h = waitbar(0,'Please wait...');steps = 1000;for step = 1:stepsrun('resizeingDONTDELETE.m'); waitbar(step / steps)endclose(h)
here I want the results as follow,
- when push button is clicked wait button should be open and should show time as zero
- time should be increased with time taken to executing the script
- after executing wait bar should be disappered
can anyone help me …….
Best Answer