jacexh / pyautoit

Python binding for AutoItX3.dll
MIT License
269 stars 74 forks source link

WindowsError: [Error 193] %1 is not a valid Win32 application #19

Closed fenchu closed 4 years ago

fenchu commented 6 years ago

Hi have a win10 64bit, same error on python 2.7.14 and 6.3.6:

d:\autoit
λ uname -a
MSYS_NT-10.0 MB-PC 2.6.0(0.304/5/3) 2016-09-09 09:46 x86_64 Msys

d:\autoit
λ pip install pyautoit
Collecting pyautoit
  Using cached PyAutoIt-0.4.zip
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "c:\users\morten~1.sen\appdata\local\temp\pip-build-zespsl\pyautoit\setup.py", line 9, in <module>
        import autoit
      File "autoit\__init__.py", line 6, in <module>
        from .autoit import options, properties, commands
      File "autoit\autoit.py", line 28, in <module>
        AUTO_IT = ctypes.windll.LoadLibrary(dll_path)
      File "c:\dist\python27\lib\ctypes\__init__.py", line 444, in LoadLibrary
        return self._dlltype(name)
      File "c:\dist\python27\lib\ctypes\__init__.py", line 366, in __init__
        self._handle = _dlopen(self._name, mode)
    WindowsError: [Error 193] %1 is not a valid Win32 application

Any help very apperciated. This is supposed to be a standalone docker container in Azure which means it must be win10 or win2016.

Thanks, MortenB, Oslo, Norway

davidcaron commented 6 years ago

I think this is related to PR #8 and version 0.5 not being released on Pypi.

lachlan-eagling commented 6 years ago

Is there any info on when v0.5 will be released to Pypi?

evan667788 commented 5 years ago

https://github.com/jacexh/pyautoit/issues/24, see the solution here

jenny525609 commented 5 years ago

请问楼主这个问题是怎么解决的啊 我也遇到了这个问题

evan667788 commented 5 years ago

请问楼主这个问题是怎么解决的啊 我也遇到了这个问题

if your windows version is 64 version, there is some error if you install directly. just follow the below instruction. first you need to download autoit zip file ,then unzip it. you need to change something in autoit.py in line 15,change dll = "AutoItX3.dll" to dll = "AutoItX3_x64.dll", then use python setup.py install , you will succeed

evan667788 commented 5 years ago

请问楼主这个问题是怎么解决的啊 我也遇到了这个问题

看我上面的回复,要修改一个值

Bamgm14 commented 5 years ago

请问楼主这个问题是怎么解决的啊 我也遇到了这个问题

if your windows version is 64 version, there is some error if you install directly. just follow the below instruction. first you need to download autoit zip file ,then unzip it. you need to change something in autoit.py in line 15,change dll = "AutoItX3.dll" to dll = "AutoItX3_x64.dll", then use python setup.py install , you will succeed

You Are My Savoir, Please Branch Your Version of the directory

jacexh commented 4 years ago

I've uploaded a new version 0.6.0 to pypi. please upgrade local package