<br><br><div><span class="gmail_quote">2008/2/1, William Hubbard &lt;<a href="mailto:billhubard@gmail.com">billhubard@gmail.com</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I&#39;m running into problems trying to use the MenuDemo (<a href="http://blog.leugim.com.mx/index.php/2008/01/03/seaside-menus/" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://blog.leugim.com.mx/index.php/2008/01/03/seaside-menus/</a>) approach and Tasks. Take a look the following scenario:<br>

<br>I&#39;m using a MainComponent (like MDMain in the tutorial), and this holds a task instance variable to the MainTask and a content iVar for the menu item components (initialized with a &quot;null&quot; component, WAComponent) . In the go method I have:<br>

<br>self loginUser ifTrue: [<br>&nbsp;&nbsp;&nbsp; self isolate: [ <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; result := self call: WelcomeComponent new<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (more calls here)<br>&nbsp;&nbsp;&nbsp; ]<br>]<br><br>Therefore my UI is like this:<br><br>&nbsp;&nbsp;&nbsp; LoginComponent<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; true<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;<br>The user is ok, then shows the Menu  from MainComponent (the menu is rendered only if the user is authenticated) and the WelcomeComponent from the task. (content still would be just WAComponent like the tutorial)<br>

<br>| &nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp; | <br>|&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp; |<br>| Menu |&nbsp; WelcomeComponent <br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br><br>When I click a menu item, content needs to be replaced with the NewComponentFromMenu, but the WelcomeComponent is still there, displayed below the NewComponentFromMenu:<br>

<br><br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | <br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>| Menu |&nbsp; NewComponentFromMenu<br>|&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp; |<br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp; WelcomeComponent<br>|&nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; |<br><br>I understand this happens because the MenuDemo do not use call: message, but I don&#39;t know how to &quot;replace&quot; the WelcomeComponent with the NewComponentFromMenu when a menu item is clicked. I tried setting the content iVar to the WelcomeComponent when enters the isolate: but this just shows two times the WelcomeComponent:<br>

<br>|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | <br>
|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>
| Menu |&nbsp; WelcomeComponent<br>
|&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp; |<br>
|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>
|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |<br>
|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp; WelcomeComponent<br>
|&nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; |<br>
<br><br>Any idea how to solve this?<br>Thanks</blockquote><div><br><br>I forgot to paste the current main render method I&#39;m using:<br><br>MainComponent&gt;&gt;renderContentOn: html<br><br>&nbsp;&nbsp; ( self username isAuthenticated ] )<br>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; ifTrue: [ html render: menu ].<br>&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; html render: content.<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; html render: task<br><br><br></div></div>