Effacer les filtres
Effacer les filtres

close a specific figure file

2 vues (au cours des 30 derniers jours)
Elysi Cochin
Elysi Cochin le 14 Juin 2014
Modifié(e) : Elysi Cochin le 14 Juin 2014
i display a table in a figure file...
now i want to close this file,
i did
close 'ANALYSIS'
and it worked, but if it does not exists it shows error that file does not exists...
how to check if a figure of ANALYSIS name exists
if exist('ANALYSIS', 'file')
close 'ANALYSIS'
end
this is not working for me... please do reply...

Réponse acceptée

Azzi Abdelmalek
Azzi Abdelmalek le 14 Juin 2014
Modifié(e) : Azzi Abdelmalek le 14 Juin 2014
You can use try function
try
close('ANALYSIS')
end
%Or you can use
ob=findobj('type','figure','name','ANALYSIS')
close(ob)
  1 commentaire
Elysi Cochin
Elysi Cochin le 14 Juin 2014
thank you so much sir.... thanks a lot....

Connectez-vous pour commenter.

Plus de réponses (0)

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