Hey, I thought about the Destroy, make new, but I have run into a problem there, Destroy and Dispose both delete all of the Widgets packed inside of them, is there anyway to toss out the table but not the widgets packed inside?&nbsp; <br>
<br>BIlly<br><br><div class="gmail_quote">On Sat, Jun 28, 2008 at 3:23 PM, Michael Hutchinson &lt;<a href="mailto:m.j.hutchinson@gmail.com">m.j.hutchinson@gmail.com</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d">On Sat, Jun 28, 2008 at 1:52 PM, Billy Schoenberg &lt;<a href="mailto:wasbridge@gmail.com">wasbridge@gmail.com</a>&gt; wrote:<br>
&gt; Hey,<br>
&gt;<br>
&gt; Thanks for the response. I do not think the code I use to reattch them is an<br>
&gt; issue, but I have attached it below. &nbsp;The reason I do not think its an<br>
&gt; issues is because if i comment out those lines I showed you last e-mail the<br>
&gt; program does not crash, it just piles widgets on top of each other. &nbsp;Also<br>
&gt; this code works just fine on Windows (all versions) and Linux (SUSE and<br>
&gt; Ubuntu) I use the &quot;Native Version&quot; of GTK on OSX 10.5 with Mono 1.9.1 that I<br>
<br>
</div>Ah. Yeah, that&#39;s the followup I was going to ask. If it works fine on<br>
linux and windows, the OS X &quot;native&quot; GTK port is probably to blame.<br>
It&#39;s nowhere near as mature as the other GTK ports.<br>
<br>
You could use the X11 version of GTK on OS X for now, though it&#39;s less<br>
convenient to install, as it requires X11.<br>
<div class="Ih2E3d"><br>
&gt; installed 3 or so months ago. &nbsp;Do you have any ideas about a work around,<br>
&gt; another way to remove widgets from a table?<br>
<br>
</div>Firstly, it&#39;s bad in a &quot;foreach&quot; to modify the collection over which<br>
you&#39;re iterating, since the enumerator object usually becomes invalid<br>
(in fact, most of the .NET collections will throw exceptions if you<br>
try this). Try this:<br>
<br>
while (controller.GTKObjectPropertiesTable.Children.Count &gt; 0)<br>
 &nbsp; &nbsp;controller.GTKObjectPropertiesTable.Remove(controller.GTKObjectPropertiesTable.Children[0]);<br>
<br>
A workaround could be to do<br>
<br>
controller.GTKObjectPropertiesTable.Visible = false;<br>
<br>
or since you&#39;re clearing the entire table, just Destroy() it and<br>
create a new one.<br>
<br>
Also, doesn&#39;t keeping a widget on your controller violate MVC? :)<br>
<font color="#888888"><br>
--<br>
</font><div><div></div><div class="Wj3C7c">Michael Hutchinson<br>
<a href="http://mjhutchinson.com" target="_blank">http://mjhutchinson.com</a><br>
</div></div></blockquote></div><br>