AnsweredAssumed Answered

Unable to import arcpy via Pycharm

Question asked by ardiarmanto on Feb 18, 2019
Latest reply on Feb 27, 2019 by dchiang

I am trying to build python scripts in Pycharm to run in ArcGIS background processing ArcGISx6410.5. When I run a script which includes "import arcpy" I get the following Error message:

 

Traceback (most recent call last):
File "D:/WWF - Sustainable Hydropower/FRA/Code/f1_zonal_stats.py", line 8, in <module>
import arcpy
File "C:\Program Files (x86)\ArcGIS\Desktop10.5\ArcPy\arcpy\__init__.py", line 22, in <module>
from arcpy.geoprocessing import gp
File "C:\Program Files (x86)\ArcGIS\Desktop10.5\ArcPy\arcpy\geoprocessing\__init__.py", line 14, in <module>
from _base import *
File "C:\Program Files (x86)\ArcGIS\Desktop10.5\ArcPy\arcpy\geoprocessing\_base.py", line 14, in <module>
import arcgisscripting
ImportError: DLL load failed: %1 is not a valid Win32 application.

Could anyone help me to notice and solve this problem? I am the beginner user of Pycharm so it would be good if anyone could give me the steps on more details

Outcomes