Hi Antoni,<br><br>You can configure different layerstores and layercontainers and manually add those to your tree panel. See the code below:<br><br>           var baseLayerStore = new GeoExt.data.LayerStore({<br>                map: map,<br>

                initDir: 0,<br>                layers: [ghyb, gsat, gstreets]<br>            });<br>            <br>            var themeLayerStore = new GeoExt.data.LayerStore({<br>                map: map,<br>                initDir: 0,<br>

                layers: [lim_bac, lim_arht]<br>            });<br>            <br>            var baseLayerCont = new GeoExt.tree.BaseLayerContainer({<br>                text: &#39;Cartografia de base&#39;,<br>                layerStore: baseLayerStore,<br>
                expanded: true,<br>                allowDrop: false<br>            });<br>            <br>            var themeLayerCont = new GeoExt.tree.LayerContainer({<br>                text: &#39;Área de jurisdição da ARH Tejo&#39;,<br>
                expanded: true,<br>                layerStore: themeLayerStore,<br>            });<br><br>Now you just need to append the layercontainers into your tree root node like the following<br><br>treeroot.appendChild(baseLayerCont);<br>
treeroot.appendChild(themeLayerCont);<br><br>Hope this helps.<br><br>Best regards,<br><br>Hugo<br>           <br><br><div class="gmail_quote">On Thu, Dec 9, 2010 at 1:48 PM, Vidal, Antoni <span dir="ltr">&lt;<a href="mailto:antoni.vidal@icc.cat" target="_blank">antoni.vidal@icc.cat</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div link="blue" vlink="purple" lang="CA"><div><p class="MsoNormal">Hello,</p><p class="MsoNormal"> </p><p class="MsoNormal">I have a treepanel built by the following code in layout.js:</p><p class="MsoNormal"> </p><p class="MsoNormal">

items: [{</p><p class="MsoNormal">                title: &#39;Capes&#39;,</p><p class="MsoNormal">    xtype: &quot;treepanel&quot;,</p><p class="MsoNormal">    loader: new Ext.tree.TreeLoader({</p><p class="MsoNormal">        applyLoader: false</p>

<p class="MsoNormal">    }),</p><p class="MsoNormal">                rootVisible: false,</p><p class="MsoNormal">    root: {</p><p class="MsoNormal">                               children: createChildren()</p><p class="MsoNormal">

    }</p><p class="MsoNormal">}</p><p class="MsoNormal"> </p><p class="MsoNormal">And:</p><p class="MsoNormal"> </p><p class="MsoNormal">var createChildren = function(){</p><p class="MsoNormal">                return [{</p>

<p class="MsoNormal">                                                               &quot;nodeType&quot;: &quot;gx_baselayercontainer&quot;,</p><p class="MsoNormal">                                                               &quot;expanded&quot;: true</p>

<p class="MsoNormal">                                               },{</p><p class="MsoNormal">                                                               &quot;nodeType&quot;: &quot;gx_overlaylayercontainer&quot;,</p>

<p class="MsoNormal">                                                               &quot;expanded&quot;: false</p><p class="MsoNormal">                                               }]</p><p class="MsoNormal">};</p><p class="MsoNormal">

 </p><p class="MsoNormal">I would like to customize the organisation in different folders and different order of layers, and not two folders  “Base Layer” and “Overlays” <span><span lang="EN">which is what I get by default.</span></span></p>

<p class="MsoNormal"><span><span lang="EN"> </span></span></p><p class="MsoNormal"><span><span lang="EN">How can I do ?</span></span></p><p class="MsoNormal"><span><span lang="EN"> </span></span></p><p class="MsoNormal">
<span><span lang="EN">Thank’s in advance</span></span></p>
<p class="MsoNormal"> </p><p class="MsoNormal"><b><span style="font-size: 10pt; color: rgb(13, 13, 13);">Antoni Vidal</span></b><span style="color: rgb(13, 13, 13);"></span></p><p class="MsoNormal"><span style="font-size: 10pt; color: gray;">Unitat d&#39;Aplicacions SIG-WEB<br>

<a href="http://mercuri.icc.cat/website/mob_nf/mob1/mob2/inici2.htm?CONSULTA=Institut%20Cartogr%25E0fic%20de%20Catalunya&amp;XYADDRESS=429486:4580392" target="_blank"><span style="color: gray;">Institut Cartogràfic de Catalunya</span></a><br>

Parc de Montjuïc, E-08038 Barcelona<br>Tel. (+34) 93 567 15 00 (ext. 3228)<br><a href="http://www.icc.cat/" target="_blank"><span style="color: blue;">www.icc.cat</span></a></span><span style="color: rgb(31, 73, 125);"></span></p>

<p class="MsoNormal"> </p></div></div><br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@geoext.org" target="_blank">Users@geoext.org</a><br>
<a href="http://www.geoext.org/cgi-bin/mailman/listinfo/users" target="_blank">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Hugo Martins<br>LabNT - ISEGI UNL<br>Campus de Campolide<br>1070-312 Lisboa<br>N 38°43&#39;56.84&quot;, W 9°9&#39;35.74&quot;<br>