<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216</link>
    <title>MATLAB Central Newsreader - Visible figure has no gui handle. Why?</title>
    <description>Feed for thread: Visible figure has no gui handle. Why?</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2010 by The MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>The MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Mon, 27 Aug 2007 18:43:58 -0400</pubDate>
      <title>Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389573</link>
      <author>G.A.M. </author>
      <description>Hello. I have an application that creates and displays a&lt;br&gt;
figure (as the main window for the GUI). The figure is&lt;br&gt;
displayed on screen, but the gui handle doesn't exist&lt;br&gt;
immediately after the figure is created.&lt;br&gt;
&lt;br&gt;
Executing h=findobj shows me that the figure and all its&lt;br&gt;
uicontrols are not among the existing objects even though&lt;br&gt;
the figure is currently visible on the screen.&lt;br&gt;
&lt;br&gt;
Where can I find basic information about why a gui handle&lt;br&gt;
would be cleared or removed and how to prevent this from&lt;br&gt;
happening? &lt;br&gt;
&lt;br&gt;
I posted a related question here:&lt;br&gt;
&lt;a href=&quot;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&quot;&gt;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
That question has more details and replies there would also&lt;br&gt;
help, but I think this question is really the heart of my&lt;br&gt;
issue. Thank you.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Mon, 27 Aug 2007 19:14:14 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389575</link>
      <author>roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)</author>
      <description>In article &amp;lt;fav61d$7a5$1@fred.mathworks.com&amp;gt;, G.A.M.  &amp;lt;x0zero@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt;Hello. I have an application that creates and displays a&lt;br&gt;
&amp;gt;figure (as the main window for the GUI). The figure is&lt;br&gt;
&amp;gt;displayed on screen, but the gui handle doesn't exist&lt;br&gt;
&amp;gt;immediately after the figure is created.&lt;br&gt;
&lt;br&gt;
&amp;gt;Executing h=findobj shows me that the figure and all its&lt;br&gt;
&amp;gt;uicontrols are not among the existing objects even though&lt;br&gt;
&amp;gt;the figure is currently visible on the screen.&lt;br&gt;
&lt;br&gt;
The HandleVisibility property of the figure has been set to 'off'.&lt;br&gt;
&lt;br&gt;
See findall() and allchild()&lt;br&gt;
-- &lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;Okay, buzzwords only. Two syllables, tops.  -- Laurie Anderson&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Mon, 27 Aug 2007 19:33:44 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389580</link>
      <author>G.A.M. </author>
      <description>Hi. Thank you for your tips. I now understand a bit about&lt;br&gt;
handle visibility (and I now have some clues about what to&lt;br&gt;
search for in help).&lt;br&gt;
&lt;br&gt;
Using the property inspector I saw that the figure's&lt;br&gt;
HandleVisibility property was set to 'callback'. I changed&lt;br&gt;
it to 'on', as advised here:&lt;br&gt;
&lt;a href=&quot;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&quot;&gt;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
However, that did not change the fact that my code cannot&lt;br&gt;
find the handle. Apparently the HandleVisibility property is&lt;br&gt;
&amp;nbsp;later being set to 'off' by some process I'm not aware of.&lt;br&gt;
&lt;br&gt;
What built-in functions would set HandleVisibility to off? I&lt;br&gt;
haven't written any code to do that, so I'm not sure why it&lt;br&gt;
is happening. I appreciate any other tips.&lt;br&gt;
&lt;br&gt;
roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson) wrote in&lt;br&gt;
message &amp;lt;fav7q6$d5g$1@canopus.cc.umanitoba.ca&amp;gt;...&lt;br&gt;
&amp;gt; In article &amp;lt;fav61d$7a5$1@fred.mathworks.com&amp;gt;, G.A.M. &lt;br&gt;
&amp;lt;x0zero@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; &amp;gt;Hello. I have an application that creates and displays a&lt;br&gt;
&amp;gt; &amp;gt;figure (as the main window for the GUI). The figure is&lt;br&gt;
&amp;gt; &amp;gt;displayed on screen, but the gui handle doesn't exist&lt;br&gt;
&amp;gt; &amp;gt;immediately after the figure is created.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt;Executing h=findobj shows me that the figure and all its&lt;br&gt;
&amp;gt; &amp;gt;uicontrols are not among the existing objects even though&lt;br&gt;
&amp;gt; &amp;gt;the figure is currently visible on the screen.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; The HandleVisibility property of the figure has been set&lt;br&gt;
to 'off'.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; See findall() and allchild()&lt;br&gt;
&amp;gt; -- &lt;br&gt;
&amp;gt;    Okay, buzzwords only. Two syllables, tops.  -- Laurie&lt;br&gt;
Anderson&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Wed, 29 Aug 2007 20:32:54 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389928</link>
      <author>G.A.M. </author>
      <description>Hello. I have been stumped by this problem for several days&lt;br&gt;
now. Using the tips provided previously, I have been&lt;br&gt;
debugging the problem. However, I still get an 'Invalid&lt;br&gt;
handle' error when using get('Tag', 'figureM'). &lt;br&gt;
&lt;br&gt;
Below is some interesting info that shows the figure exists&lt;br&gt;
and HandleVisibility = on. At the moment I execute these&lt;br&gt;
statements, the figure is visible on screen. Yet I still get&lt;br&gt;
an 'Invalid handle' error as shown below. Any tips? &lt;br&gt;
&lt;br&gt;
&lt;br&gt;
K&amp;gt;&amp;gt; h1 = findall(0, 'Tag', 'figureM')&lt;br&gt;
&lt;br&gt;
h1 =&lt;br&gt;
&lt;br&gt;
&amp;nbsp;&amp;nbsp;399.0098&lt;br&gt;
&lt;br&gt;
K&amp;gt;&amp;gt; get(h1)&lt;br&gt;
	Alphamap = [ (1 by 64) double array]&lt;br&gt;
	BackingStore = on&lt;br&gt;
	CloseRequestFcn = closereq&lt;br&gt;
	Color = [0.709804 0.807843 0.909804]&lt;br&gt;
	Colormap = [ (64 by 3) double array]&lt;br&gt;
	CurrentAxes = [406.01]&lt;br&gt;
	CurrentCharacter = &lt;br&gt;
	CurrentObject = [32.0095]&lt;br&gt;
	CurrentPoint = [230 22]&lt;br&gt;
	DockControls = off&lt;br&gt;
	DoubleBuffer = on&lt;br&gt;
	FileName = [ (1 by 84) char array]&lt;br&gt;
	FixedColors = [ (12 by 3) double array]&lt;br&gt;
	IntegerHandle = off&lt;br&gt;
	InvertHardcopy = on&lt;br&gt;
	KeyPressFcn = [ (1 by 1) function_handle array]&lt;br&gt;
	KeyReleaseFcn = &lt;br&gt;
	MenuBar = none&lt;br&gt;
	MinColormap = [64]&lt;br&gt;
	Name = Figure_M&lt;br&gt;
	NextPlot = add&lt;br&gt;
	NumberTitle = off&lt;br&gt;
	PaperUnits = inches&lt;br&gt;
	PaperOrientation = portrait&lt;br&gt;
	PaperPosition = [0.25 2.5 8 6]&lt;br&gt;
	PaperPositionMode = manual&lt;br&gt;
	PaperSize = [8.5 11]&lt;br&gt;
	PaperType = usletter&lt;br&gt;
	Pointer = arrow&lt;br&gt;
	PointerShapeCData = [ (16 by 16) double array]&lt;br&gt;
	PointerShapeHotSpot = [1 1]&lt;br&gt;
	Position = [72 34 1494 1031]&lt;br&gt;
	Renderer = painters&lt;br&gt;
	RendererMode = auto&lt;br&gt;
	Resize = on&lt;br&gt;
	ResizeFcn = &lt;br&gt;
	SelectionType = normal&lt;br&gt;
	ShareColors = on&lt;br&gt;
	ToolBar = auto&lt;br&gt;
	Units = pixels&lt;br&gt;
	WindowButtonDownFcn = &lt;br&gt;
	WindowButtonMotionFcn = &lt;br&gt;
	WindowButtonUpFcn = &lt;br&gt;
	WindowScrollWheelFcn = &lt;br&gt;
	WindowStyle = normal&lt;br&gt;
	WVisual = 00 (RGB 32  GDI, Bitmap, Window)&lt;br&gt;
	WVisualMode = auto&lt;br&gt;
&lt;br&gt;
	BeingDeleted = off&lt;br&gt;
	ButtonDownFcn = &lt;br&gt;
	Children = [ (16 by 1) double array]&lt;br&gt;
	Clipping = on&lt;br&gt;
	CreateFcn = &lt;br&gt;
	DeleteFcn = &lt;br&gt;
	BusyAction = queue&lt;br&gt;
	HandleVisibility = on&lt;br&gt;
	HitTest = on&lt;br&gt;
	Interruptible = on&lt;br&gt;
	Parent = [0]&lt;br&gt;
	Selected = off&lt;br&gt;
	SelectionHighlight = on&lt;br&gt;
	Tag = figureM&lt;br&gt;
	Type = figure&lt;br&gt;
	UIContextMenu = []&lt;br&gt;
	UserData = []&lt;br&gt;
	Visible = on&lt;br&gt;
&lt;br&gt;
K&amp;gt;&amp;gt; get('Tag', 'figureM')&lt;br&gt;
??? Error using ==&amp;gt; get&lt;br&gt;
Invalid handle.&lt;br&gt;
&lt;br&gt;
K&amp;gt;&amp;gt; &lt;br&gt;
&lt;br&gt;
&quot;G.A.M. &quot; &amp;lt;x0zero@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;lt;fav8uo$5oc$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; Hi. Thank you for your tips. I now understand a bit about&lt;br&gt;
&amp;gt; handle visibility (and I now have some clues about what to&lt;br&gt;
&amp;gt; search for in help).&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Using the property inspector I saw that the figure's&lt;br&gt;
&amp;gt; HandleVisibility property was set to 'callback'. I changed&lt;br&gt;
&amp;gt; it to 'on', as advised here:&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;a href=&quot;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&quot;&gt;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&lt;/a&gt;&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; However, that did not change the fact that my code cannot&lt;br&gt;
&amp;gt; find the handle. Apparently the HandleVisibility property is&lt;br&gt;
&amp;gt;  later being set to 'off' by some process I'm not aware of.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; What built-in functions would set HandleVisibility to off? I&lt;br&gt;
&amp;gt; haven't written any code to do that, so I'm not sure why it&lt;br&gt;
&amp;gt; is happening. I appreciate any other tips.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson) wrote in&lt;br&gt;
&amp;gt; message &amp;lt;fav7q6$d5g$1@canopus.cc.umanitoba.ca&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; In article &amp;lt;fav61d$7a5$1@fred.mathworks.com&amp;gt;, G.A.M. &lt;br&gt;
&amp;gt; &amp;lt;x0zero@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;Hello. I have an application that creates and displays a&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;figure (as the main window for the GUI). The figure is&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;displayed on screen, but the gui handle doesn't exist&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;immediately after the figure is created.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;Executing h=findobj shows me that the figure and all its&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;uicontrols are not among the existing objects even though&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;the figure is currently visible on the screen.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; The HandleVisibility property of the figure has been set&lt;br&gt;
&amp;gt; to 'off'.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; See findall() and allchild()&lt;br&gt;
&amp;gt; &amp;gt; -- &lt;br&gt;
&amp;gt; &amp;gt;    Okay, buzzwords only. Two syllables, tops.  -- Laurie&lt;br&gt;
&amp;gt; Anderson&lt;br&gt;
&amp;gt; &lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Wed, 29 Aug 2007 21:10:04 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389939</link>
      <author>Loren Shure</author>
      <description>In article &amp;lt;fb4l5m$4u4$1@fred.mathworks.com&amp;gt;, x0zero@gmail.com says...&lt;br&gt;
&amp;gt; Hello. I have been stumped by this problem for several days&lt;br&gt;
&amp;gt; now. Using the tips provided previously, I have been&lt;br&gt;
&amp;gt; debugging the problem. However, I still get an 'Invalid&lt;br&gt;
&amp;gt; handle' error when using get('Tag', 'figureM'). &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Below is some interesting info that shows the figure exists&lt;br&gt;
&amp;gt; and HandleVisibility = on. At the moment I execute these&lt;br&gt;
&amp;gt; statements, the figure is visible on screen. Yet I still get&lt;br&gt;
&amp;gt; an 'Invalid handle' error as shown below. Any tips? &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; K&amp;gt;&amp;gt; h1 = findall(0, 'Tag', 'figureM')&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; h1 =&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt;   399.0098&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; K&amp;gt;&amp;gt; get(h1)&lt;br&gt;
&amp;gt; 	Alphamap = [ (1 by 64) double array]&lt;br&gt;
&amp;gt; 	BackingStore = on&lt;br&gt;
&amp;gt; 	CloseRequestFcn = closereq&lt;br&gt;
&amp;gt; 	Color = [0.709804 0.807843 0.909804]&lt;br&gt;
&amp;gt; 	Colormap = [ (64 by 3) double array]&lt;br&gt;
&amp;gt; 	CurrentAxes = [406.01]&lt;br&gt;
&amp;gt; 	CurrentCharacter = &lt;br&gt;
&amp;gt; 	CurrentObject = [32.0095]&lt;br&gt;
&amp;gt; 	CurrentPoint = [230 22]&lt;br&gt;
&amp;gt; 	DockControls = off&lt;br&gt;
&amp;gt; 	DoubleBuffer = on&lt;br&gt;
&amp;gt; 	FileName = [ (1 by 84) char array]&lt;br&gt;
&amp;gt; 	FixedColors = [ (12 by 3) double array]&lt;br&gt;
&amp;gt; 	IntegerHandle = off&lt;br&gt;
&amp;gt; 	InvertHardcopy = on&lt;br&gt;
&amp;gt; 	KeyPressFcn = [ (1 by 1) function_handle array]&lt;br&gt;
&amp;gt; 	KeyReleaseFcn = &lt;br&gt;
&amp;gt; 	MenuBar = none&lt;br&gt;
&amp;gt; 	MinColormap = [64]&lt;br&gt;
&amp;gt; 	Name = Figure_M&lt;br&gt;
&amp;gt; 	NextPlot = add&lt;br&gt;
&amp;gt; 	NumberTitle = off&lt;br&gt;
&amp;gt; 	PaperUnits = inches&lt;br&gt;
&amp;gt; 	PaperOrientation = portrait&lt;br&gt;
&amp;gt; 	PaperPosition = [0.25 2.5 8 6]&lt;br&gt;
&amp;gt; 	PaperPositionMode = manual&lt;br&gt;
&amp;gt; 	PaperSize = [8.5 11]&lt;br&gt;
&amp;gt; 	PaperType = usletter&lt;br&gt;
&amp;gt; 	Pointer = arrow&lt;br&gt;
&amp;gt; 	PointerShapeCData = [ (16 by 16) double array]&lt;br&gt;
&amp;gt; 	PointerShapeHotSpot = [1 1]&lt;br&gt;
&amp;gt; 	Position = [72 34 1494 1031]&lt;br&gt;
&amp;gt; 	Renderer = painters&lt;br&gt;
&amp;gt; 	RendererMode = auto&lt;br&gt;
&amp;gt; 	Resize = on&lt;br&gt;
&amp;gt; 	ResizeFcn = &lt;br&gt;
&amp;gt; 	SelectionType = normal&lt;br&gt;
&amp;gt; 	ShareColors = on&lt;br&gt;
&amp;gt; 	ToolBar = auto&lt;br&gt;
&amp;gt; 	Units = pixels&lt;br&gt;
&amp;gt; 	WindowButtonDownFcn = &lt;br&gt;
&amp;gt; 	WindowButtonMotionFcn = &lt;br&gt;
&amp;gt; 	WindowButtonUpFcn = &lt;br&gt;
&amp;gt; 	WindowScrollWheelFcn = &lt;br&gt;
&amp;gt; 	WindowStyle = normal&lt;br&gt;
&amp;gt; 	WVisual = 00 (RGB 32  GDI, Bitmap, Window)&lt;br&gt;
&amp;gt; 	WVisualMode = auto&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 	BeingDeleted = off&lt;br&gt;
&amp;gt; 	ButtonDownFcn = &lt;br&gt;
&amp;gt; 	Children = [ (16 by 1) double array]&lt;br&gt;
&amp;gt; 	Clipping = on&lt;br&gt;
&amp;gt; 	CreateFcn = &lt;br&gt;
&amp;gt; 	DeleteFcn = &lt;br&gt;
&amp;gt; 	BusyAction = queue&lt;br&gt;
&amp;gt; 	HandleVisibility = on&lt;br&gt;
&amp;gt; 	HitTest = on&lt;br&gt;
&amp;gt; 	Interruptible = on&lt;br&gt;
&amp;gt; 	Parent = [0]&lt;br&gt;
&amp;gt; 	Selected = off&lt;br&gt;
&amp;gt; 	SelectionHighlight = on&lt;br&gt;
&amp;gt; 	Tag = figureM&lt;br&gt;
&amp;gt; 	Type = figure&lt;br&gt;
&amp;gt; 	UIContextMenu = []&lt;br&gt;
&amp;gt; 	UserData = []&lt;br&gt;
&amp;gt; 	Visible = on&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; K&amp;gt;&amp;gt; get('Tag', 'figureM')&lt;br&gt;
&amp;gt; ??? Error using ==&amp;gt; get&lt;br&gt;
&amp;gt; Invalid handle.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; K&amp;gt;&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &quot;G.A.M. &quot; &amp;lt;x0zero@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;gt; &amp;lt;fav8uo$5oc$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; Hi. Thank you for your tips. I now understand a bit about&lt;br&gt;
&amp;gt; &amp;gt; handle visibility (and I now have some clues about what to&lt;br&gt;
&amp;gt; &amp;gt; search for in help).&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Using the property inspector I saw that the figure's&lt;br&gt;
&amp;gt; &amp;gt; HandleVisibility property was set to 'callback'. I changed&lt;br&gt;
&amp;gt; &amp;gt; it to 'on', as advised here:&lt;br&gt;
&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&quot;&gt;http://www.mathworks.cn/matlabcentral/newsreader/view_thread/155215&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; However, that did not change the fact that my code cannot&lt;br&gt;
&amp;gt; &amp;gt; find the handle. Apparently the HandleVisibility property is&lt;br&gt;
&amp;gt; &amp;gt;  later being set to 'off' by some process I'm not aware of.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; What built-in functions would set HandleVisibility to off? I&lt;br&gt;
&amp;gt; &amp;gt; haven't written any code to do that, so I'm not sure why it&lt;br&gt;
&amp;gt; &amp;gt; is happening. I appreciate any other tips.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson) wrote in&lt;br&gt;
&amp;gt; &amp;gt; message &amp;lt;fav7q6$d5g$1@canopus.cc.umanitoba.ca&amp;gt;...&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; In article &amp;lt;fav61d$7a5$1@fred.mathworks.com&amp;gt;, G.A.M. &lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;x0zero@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;Hello. I have an application that creates and displays a&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;figure (as the main window for the GUI). The figure is&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;displayed on screen, but the gui handle doesn't exist&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;immediately after the figure is created.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;Executing h=findobj shows me that the figure and all its&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;uicontrols are not among the existing objects even though&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;the figure is currently visible on the screen.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; The HandleVisibility property of the figure has been set&lt;br&gt;
&amp;gt; &amp;gt; to 'off'.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; See findall() and allchild()&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; -- &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;    Okay, buzzwords only. Two syllables, tops.  -- Laurie&lt;br&gt;
&amp;gt; &amp;gt; Anderson&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&lt;br&gt;
You have to pass possible handles or ancestors into findall.  These all &lt;br&gt;
worked for me as I expected:&lt;br&gt;
&lt;br&gt;
h = figure('Tag','figureM');&lt;br&gt;
h(2) = figure;&lt;br&gt;
&lt;br&gt;
&amp;gt;&amp;gt;findall(h,'tag','figureM')&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;1&lt;br&gt;
&amp;gt;&amp;gt;findall(0,'tag','figureM')&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;1&lt;br&gt;
&amp;gt;&amp;gt;findall(h(2),'tag','figureM')&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;Empty matrix: 0-by-1&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
-- &lt;br&gt;
Loren&lt;br&gt;
&lt;a href=&quot;http://blogs.mathworks.com/loren/&quot;&gt;http://blogs.mathworks.com/loren/&lt;/a&gt;&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Wed, 29 Aug 2007 21:38:17 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389943</link>
      <author>G.A.M. </author>
      <description>Hi Loren,&lt;br&gt;
Thanks for your reply. Unfortunately, I don't quite&lt;br&gt;
understand it yet. I appreciate a clarification :)&lt;br&gt;
&lt;br&gt;
My issue is that my main gui is displayed on the screen but&lt;br&gt;
when I attempt to get a handle to it in my m-file code I get&lt;br&gt;
an error that indicates the value returned by findobj('Tag',&lt;br&gt;
'figureM') isn't valid. This seems very strange.&lt;br&gt;
&lt;br&gt;
I simply want to have a gui figure display on the screen and&lt;br&gt;
remain accessible/valid while the user clicks buttons and&lt;br&gt;
causes various plots to be displayed. This seems like the&lt;br&gt;
normal behavior one would expect, so I'm baffled that I'm&lt;br&gt;
getting invalid handle errors - especially because I can see&lt;br&gt;
the figure on the screen at the time of the errors.&lt;br&gt;
&lt;br&gt;
The code I pasted was executed in the workspace as an&lt;br&gt;
attempt to help me debug the problem. However, the problem&lt;br&gt;
occurs in the m-file code. I simply can't seem to use&lt;br&gt;
findobj('Tag', 'figureM') as one would expect it to be used.&lt;br&gt;
&lt;br&gt;
&amp;gt; You have to pass possible handles or ancestors into&lt;br&gt;
findall.  These all &lt;br&gt;
&amp;gt; worked for me as I expected:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; h = figure('Tag','figureM');&lt;br&gt;
&amp;gt; h(2) = figure;&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt;&amp;gt;findall(h,'tag','figureM')&lt;br&gt;
&amp;gt;    1&lt;br&gt;
&amp;gt; &amp;gt;&amp;gt;findall(0,'tag','figureM')&lt;br&gt;
&amp;gt;    1&lt;br&gt;
&amp;gt; &amp;gt;&amp;gt;findall(h(2),'tag','figureM')&lt;br&gt;
&amp;gt;    Empty matrix: 0-by-1&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; -- &lt;br&gt;
&amp;gt; Loren&lt;br&gt;
&amp;gt; &lt;a href=&quot;http://blogs.mathworks.com/loren/&quot;&gt;http://blogs.mathworks.com/loren/&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Wed, 29 Aug 2007 23:14:24 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#389956</link>
      <author>roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)</author>
      <description>In article &amp;lt;fb4l5m$4u4$1@fred.mathworks.com&amp;gt;, G.A.M.  &amp;lt;x0zero@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt;Hello. I have been stumped by this problem for several days&lt;br&gt;
&amp;gt;now. Using the tips provided previously, I have been&lt;br&gt;
&amp;gt;debugging the problem. However, I still get an 'Invalid&lt;br&gt;
&amp;gt;handle' error when using get('Tag', 'figureM'). &lt;br&gt;
&lt;br&gt;
You can't get('Tag', 'figureM'). You can, though,&lt;br&gt;
&lt;br&gt;
get(findobj('Tag', 'figureM'))&lt;br&gt;
&lt;br&gt;
get() must be passed a handle (or list of handles) to operate on.&lt;br&gt;
-- &lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;I was very young in those days, but I was also rather dim.&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;-- Christopher Priest&lt;br&gt;
</description>
    </item>
    <item>
      <pubDate>Thu, 30 Aug 2007 21:22:05 -0400</pubDate>
      <title>Re: Visible figure has no gui handle. Why?</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/155216#390168</link>
      <author>G.A.M. </author>
      <description>Hi. Thank you for pointing out my mistake. Unfortunately,&lt;br&gt;
that was only a mistake in what I posted here, not in my&lt;br&gt;
code. I still have the problem in my code where it seems&lt;br&gt;
like figures have handle visibility off when it is set to&lt;br&gt;
on. I cannot figure it out... the code seems correct.&lt;br&gt;
&lt;br&gt;
roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson) wrote in&lt;br&gt;
message &amp;lt;fb4ukg$g6q$1@canopus.cc.umanitoba.ca&amp;gt;...&lt;br&gt;
&amp;gt; In article &amp;lt;fb4l5m$4u4$1@fred.mathworks.com&amp;gt;, G.A.M. &lt;br&gt;
&amp;lt;x0zero@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; &amp;gt;Hello. I have been stumped by this problem for several days&lt;br&gt;
&amp;gt; &amp;gt;now. Using the tips provided previously, I have been&lt;br&gt;
&amp;gt; &amp;gt;debugging the problem. However, I still get an 'Invalid&lt;br&gt;
&amp;gt; &amp;gt;handle' error when using get('Tag', 'figureM'). &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; You can't get('Tag', 'figureM'). You can, though,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; get(findobj('Tag', 'figureM'))&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; get() must be passed a handle (or list of handles) to&lt;br&gt;
operate on.&lt;br&gt;
&amp;gt; -- &lt;br&gt;
&amp;gt;    I was very young in those days, but I was also rather dim.&lt;br&gt;
&amp;gt;    -- Christopher Priest&lt;br&gt;
&lt;br&gt;
</description>
    </item>
  </channel>
</rss>
