Clear image in GUI?

4 vues (au cours des 30 derniers jours)
Kyle
Kyle le 10 Juil 2011
Commenté : Yibiao le 19 Fév 2015
Hi,
Is there another way to clear image in axes beside using the following code?
cla(handles.im1,'reset')
If i use this, it even clears the ButtonDownFcn of my axes.
Thanks

Réponse acceptée

Robert Cumming
Robert Cumming le 10 Juil 2011
cla(handles.im1)

Plus de réponses (2)

Paulo Silva
Paulo Silva le 10 Juil 2011
Just delete the children of the current axes
delete(get(gca,'Children'))
The buttondownfcn of the axes remains unchanged
  4 commentaires
Kyle
Kyle le 10 Juil 2011
Thanks
It works like the cla(handles.im1)
Yibiao
Yibiao le 19 Fév 2015
It works, thanks!

Connectez-vous pour commenter.


norfaizayu
norfaizayu le 30 Jan 2012
i cannot run the source code. is it just put the coding?i have 3 axes to be clear in gui. so how can i clear it?
  1 commentaire
Walter Roberson
Walter Roberson le 30 Jan 2012
Sorry, I am having difficulty understanding your question.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Interactive Control and Callbacks dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by