MATLAB Answers


Reset Button Gui

Asked by Melvin
on 8 Mar 2012
Latest activity Commented on by yogesh jain
on 8 Mar 2016

Hi everyone. What code should I put under a push button if I want to reset the inputs and outputs presented on the GUI to its most initial state? Thank you. :)




No products are associated with this question.

2 Answers

Answer by Sermed
on 13 Mar 2012

Hi Melvin The way I do it is: Under the callback function of the reset push button write: set(handles.edit1, 'value', 0)set(handles.edit2, 'string', 'default') ...... this will solve the problem if you have a limited nr of input parameters. Their might be some other smarter methodes :o)


Answer by Aldin
on 13 Mar 2012

You can try this code: Callback for your RESET BUTTON: set(handles.edit1,'String','') ('' - is empty String)


on 10 May 2013


what about if i want to make the axis empty?

axes(handles.axes1); cla;

Join the 15-year community celebration.

Play games and win prizes!

Learn more
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

MATLAB Academy

New to MATLAB?

Learn MATLAB today!