I'm trying to create a PyQGIS standalone script in windows 10 but I have some errors.
First I have read this post and I follow comment of Mr. @caiohamamura but I have semi-success I think, and I don't why happen this error.
first :
Your PYTHONHOME should be:
C:\OSGeo4W64\apps\Python27
Your PATH should include (in the beggining):
C:\OSGeo4W64\bin; C:\OSGeo4W64\apps\qgis-ltr-dev\bin
PYTHONPATH should have:
C:\OSGeo4W64\apps\qgis-ltr-dev\python
C:\OSGeo4W64\apps\qgis-ltr-dev\python\plugins
C:\OSGeo4W64\bin\python27.zip
C:\OSGeo4W64\apps\Python27\DLLs
C:\OSGeo4W64\apps\Python27
C:\OSGeo4W64\apps\Python27\lib
C:\OSGeo4W64\apps\Python27\lib\site-packages
and finally the test.
Python in cmd prompt:
Python in OSGeo shell :
Why in OSGeo shell I take this error :
ImportError: DLL load failed: ─ίΊ ▐ΪάΊ ϊΫΊάΪⁿ Ίά ίΊΪΎΏώ≤Ϊί▀ ύ ΆάϋΎ±ώ≤Ή▌Ίύ ΈίώΪ.
What am I doing wrong? What is the difference?



print sys.pathall paths is the some with only deference is on cmd is name start withC:\\OSGeo4W64and in osgeo shell isC:\\OSGEO4~1but i dont think if is wrong...third i dont have other python in my system i use olny with QGIS python..finally if i useC:\OSGeo4W64\bin\python-qgis-ltr-dev.batthen start python and i canimport qgis.core.but i need more automate way from to call any time this.bat. how to do this permanent like is in cmd now ? – hellas Nov 09 '17 at 19:26cd..pip installand other options of shell command orpython myscript.pyand more.that i need only if i select python way in osgeo shell to dont keep qgis import errors like windows cmd.exe – hellas Nov 09 '17 at 20:35