<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<div class="moz-cite-prefix"><font face="Georgia">Greetings, Ludwig.<br>
Thanks for your offer of help.<br>
However, I have no idea how to use the script.<br>
I have only used Qgis a few times.<br>
WV-Mike<br>
=============<br>
On 2/9/2026 3:18 PM, Ludwig Kniprath via QGIS-User wrote:<br>
</font></div>
<blockquote type="cite"
cite="mid:6a304005-3291-461b-98ac-95c1d4e70ca8@kni-online.de"><font
face="Georgia">Hi Mike,
<br>
</font>
<font face="Georgia"><br>
there are probably several solutions for your problem. Below a
script, which uses the imported csv-layer and creates a memory
layer for each feature.
<br>
</font>
<font face="Georgia"><br>
# active-layer = csv-import-layer
<br>
vl = iface.activeLayer()
<br>
</font>
<font face="Georgia"><br>
# the group for the single-point layers in Layer-Panel
<br>
target_group =
QgsProject.instance().layerTreeRoot().addGroup('group_1')
<br>
</font>
<font face="Georgia"><br>
# iterate through the csv-import-layer
<br>
for f in vl.getFeatures():
<br>
# create a clone of this layer with only one feature
<br>
vl_clone =
vl.materialize(QgsFeatureRequest().setFilterFids([f.id()]))
<br>
# set the name for the new layer, here using the attribute
'name' of the csv-import-layer
<br>
# adapt if necessary or create another name
<br>
vl_clone.setName(f['name'])
<br>
# parameter 2 False => dont't add to layerTreeRoot...
<br>
QgsProject.instance().addMapLayer(vl_clone,False)
<br>
# ...but to the above created group
<br>
target_group.insertLayer(-1, vl_clone)
<br>
</font>
<font face="Georgia"><br>
</font>
<font face="Georgia"><br>
Note: the script creates temporary memory-layers, which you must
convert to permanent layers (context-menu > Make Permament)
<br>
</font>
<font face="Georgia"><br>
</font>
<font face="Georgia"><br>
hth
<br>
</font>
<font face="Georgia"><br>
Ludwig
<br>
</font>
<font face="Georgia"><br>
Am 09.02.26 um 21:37 schrieb ERT - Mike Breiding via QGIS-User:
<br>
</font>
<blockquote type="cite"><font face="Georgia">Greetings,
<br>
I was successful in adding lat/long points to my project from
a .cvs file:
<br>
Lat,Long,Mile
<br>
-79.924454,39.709589,M 1
<br>
-79.936296,39.698546,M 2
<br>
-79.939802,39.68499,M 3
<br>
etc.
<br>
</font>
<font face="Georgia"><br>
When the points are added to my project all the of them are in
one layer that contains all the points.
<br>
I wish to have all the points as separate layers contained in
a Group.
<br>
How can I accomplish this?
<br>
</font>
<font face="Georgia"><br>
Thanks,
<br>
WV-Mike
<br>
_______________________________________________
<br>
QGIS-User mailing list
<br>
<a class="moz-txt-link-abbreviated" href="mailto:QGIS-User@lists.osgeo.org">QGIS-User@lists.osgeo.org</a>
<br>
List info: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a>
<br>
Unsubscribe:
<a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a>
<br>
</font></blockquote>
<font face="Georgia">_______________________________________________
<br>
QGIS-User mailing list
<br>
<a class="moz-txt-link-abbreviated" href="mailto:QGIS-User@lists.osgeo.org">QGIS-User@lists.osgeo.org</a>
<br>
List info: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a>
<br>
Unsubscribe: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a>
<br>
</font></blockquote>
</body>
</html>