Through QGIS API, I would like to add some tens of vector layers to QGIS, where each layer would be a single shapefile from a folder. I would then like to print (to Python console) the coordinates of all the point features in those shapefiles.
Can that be achieved with QGIS API, but outside of QGIS (through a Python editor like PyCharm/Atom for example)?
I found an API snippet how that can be achieved, but only from inside the QGIS. Is it possible to do it from PyCharm/Atom too?
I am struggling to adapt the upper code. For example, I can't even import qgis.core
module:
# coding=utf-8
import os, sys
# append QGIS Python library to python search path
sys.path.append(R"C:\Program Files\QGIS 3.10\apps\qgis\python")
# append location of DLLs to current system PATH envrionment variable
os.environ['PATH'] += R";C:\Program Files\QGIS 3.10\apps\qgis\bin;"
# examine new PATH environment variable
print (os.environ['PATH'])
import qgis
import PyQt5.QtCore
app = qgis.QtCore.QCoreApplication([]) # is this 'QGIS app'?
import qgis.core # raises an error: 'from qgis._core import * ImportError: DLL load failed: The specified procedure could not be found.'