필터 지우기
필터 지우기

close a specific figure file

조회 수: 2 (최근 30일)
Elysi Cochin
Elysi Cochin 2014년 6월 14일
편집: Elysi Cochin 2014년 6월 14일
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...

채택된 답변

Azzi Abdelmalek
Azzi Abdelmalek 2014년 6월 14일
편집: Azzi Abdelmalek 2014년 6월 14일
You can use try function
try
close('ANALYSIS')
end
%Or you can use
ob=findobj('type','figure','name','ANALYSIS')
close(ob)
  댓글 수: 1
Elysi Cochin
Elysi Cochin 2014년 6월 14일
thank you so much sir.... thanks a lot....

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Interactive Control and Callbacks에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by