1

I tried to install pythonwin26-212 from ArcGIS10.0 Desktop CD. pythonwin26-212 stops working as soon as I press "Enter" in the interactive window. (ps. I downloaded pythonwin26-212 from sourceforge too. It crashes the same way.) So, I downloaded pythonwin26-218 from sourceforge, and installed it. The pythonwin26-218 wouldn't crash but it couldn't recognize arcpy. I doubt the reason would be the unmatched directories. pythonwin is supposed to be in the same folder as numpy (?) if it was installed from the CD, but it is now in a different folder:

C:\Python26\ArcGIS10.0\Lib\site-packages\numpy

C:\Python26\Lib\site-packages\pythonwin

After I move the pythonwin folder into C:\Python26\ArcGIS10.0\Lib\site-packages\

I click the pythonwin .exe file, it wouldn't open but gives the following message:

Traceback (most recent call last): File "", line 1, in File "pywin\framework\startup.py", line 49, in import(moduleName) File "C:\Python26\ArcGIS10.0\Lib\site-packages\pythonwin\pywin\framework\intpyapp.py", line 3, in import win32con ImportError: No module named win32con

Anyone knows how to fix this? Thanks! Thanks, A.

2 Answers 2

2

First, check which Python version was installed when you did the ArcGIS 10.X install On my computer Python is installed at the following location:

C:\Python27

This will tell you which version you are working with. In my case, I have Python 2.7 installed.

Next, download the correct build of PythonWin. In my case, I would download the following PythonWin build because ArcGIS runs on a 32-bit platform and I have Python 2.7 installed.

pywin32-218.win32-py2.7.exe

If Python 2.6 is installed on your computer, you will need to download the following:

pywin32-218.win32-py2.6.exe

Finally, check to make sure PythonWin is installed at the correct location. On my computer, PythonWin is located at the following location:

C:\Python27\ArcGIS10.2\Lib\site-packages\pythonwin

6
  • This is where pythonwin installed: C:\Python26\Lib\site-packages\pythonwin I couldn't change the path while installing.
    – Apple
    Commented Jan 20, 2014 at 22:46
  • Does the following location exist on you computer: C:\Python26\ArcGIS10.0\Lib\site-packages ? Also, did you download PythonWin from the link I provided, or another?
    – Aaron
    Commented Jan 20, 2014 at 22:49
  • Yes, the location exists. It has numpy only (no pythonwin)--see the question. I installed pywin32-218.win32-py2.6 because I am using ArcGIS10.0. What is the difference between pywin32-218 and pywin32-212 btw? pywin32-212 btw is what comes with the ArcGIS CD, but pywin32-212 btw crashes.
    – Apple
    Commented Jan 20, 2014 at 23:00
  • As long as you are using the correct build pywin32-218.win32-py2.6.exe, you should be able to move the PythonWin folder to C:\Python26\ArcGIS10.0\Lib\site-packages. Once you do that try opening the GUI and importing arcpy.
    – Aaron
    Commented Jan 20, 2014 at 23:12
  • I just tried to move the folder. The exe file (green snake) wouldn't open--see the edits in the question.
    – Apple
    Commented Jan 20, 2014 at 23:23
1

Is it necessary for you to use PythonWin?

I recently upgraded from version 10 and upon starting PythonWin got the same error message that you did. I attempted to download and reinstall PythonWin but was unable to get it running. The easiest fix I found was to install PyScripter - it took a while to get used to the different program, but overall I am happier using it than PythonWin.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.