필터 지우기
필터 지우기

Adding an object to a figure created with GUIDE

조회 수: 2 (최근 30일)
waninoco
waninoco 2011년 5월 9일
Hi! Here is my question:
Is it possible to add an object (i.e. axes) to a figure that I have created with GUIDE?
I have created a *.fig with GUIDE called boton.fig with just one button. To open it I use:
h = boton
and for getting the handles I use:
handles = guihandles(h)
At this point, the variable 'handles' contains the following:
handles =
figure1: 1
pushbutton1: 200.1094
But, if I write
get(0,'CurrentFigure')
the answer is [], so, there's no current figure in spite of the recently open boton.fig. And now, if try to put some axes on that boton.fig with the command 'axes', another figure opens.
What can I do to add the axes on boton.fig and not to a new figure??

채택된 답변

Walter Roberson
Walter Roberson 2011년 5월 9일
You should be able to use
axes('Parent',handles.figure1)
  댓글 수: 1
waninoco
waninoco 2011년 5월 9일
Wow... thank you very much! It worked.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by