<div dir="ltr">Hey Walter.<div><br></div><div>Try this:</div><div><br></div><div>maplayers = QgsMapLayerRegistry.instance().mapLayers()</div><div><br></div><div>maplayers will be a dict of layerid-layer object</div><div><br></div><div>- Nathan</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Oct 13, 2014 at 7:19 PM, walter.nordmann <span dir="ltr"><<a href="mailto:walter.nordmann@web.de" target="_blank">walter.nordmann@web.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
running 2.4 /phyton programming<br>
<br>
i need the Id of one of three layers and that layer is not the active one.<br>
<br>
want to remove that unneeded layer with python.<br>
<br>
Regards<br>
<br>
walter<br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://osgeo-org.1560.x6.nabble.com/Get-layer-id-by-layer-not-by-acive-layer-tp5167152.html" target="_blank">http://osgeo-org.1560.x6.nabble.com/Get-layer-id-by-layer-not-by-acive-layer-tp5167152.html</a><br>
Sent from the Quantum GIS - User mailing list archive at Nabble.com.<br>
_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
</blockquote></div><br></div>