You are right, Nyall. The problem was the path of the vector layer.
Thank you,
Roberto
El lun., 29 oct. 2018 a las 23:54, Nyall Dawson ()
escribió:
> On Tue, 30 Oct 2018 at 06:39, Roberto Herrero
> wrote:
> >
> > getFeatures() and fields() do not seem to work in Qgis3.2
>
> They 100% work --
On Tue, 30 Oct 2018 at 06:39, Roberto Herrero wrote:
>
> getFeatures() and fields() do not seem to work in Qgis3.2
They 100% work -- if they didn't, QGIS wouldn't be good for anything
except wasting some space on your computer ;)
> # Open vector layer
> LayerName = u'Vector_layer.shp'
>
getFeatures() and fields() do not seem to work in Qgis3.2
I'm running the following pyqgis script:
=
#!/usr/bin/python
# -*- coding: utf8 -*-
import qgis.core
# Open vector layer
LayerName = u'Vector_layer.shp'
VectorLayer =