Problem using AutoIt Library on Win7 64bit

4,034 views
Skip to first unread message

Eileen Wei

unread,
Oct 7, 2010, 1:43:05 PM10/7/10
to robotframework-users
On my Win7 64bit machine, I had Python 2.7 64bit, RB 2.5.4 64bit and
pywin32-214.win-amd64-py2.7.exe installed.

I couldn't find a 64bit version for PIL, so I installed
PIL-1.1.7.win32-py2.7.exe, and it told me it couldn't find Python2.7
in the registry. I googled and copied HKLM\SOFTWARE\Python and its sub-
keys to HKLM\SOFTWARE\Wow6432Node\Python, then the PIL installer ran
successfully.

Then I downloaded and install AutoIt Library and run the test batch
file and here is what I got:

C:\RobotFramework\Extensions\AutoItLibrary\tests>RunTests.bat
==============================================================================
AutoItLibrary Windows Calculator :: Post installation self-test for
AutoItL...
==============================================================================
[ ERROR ] Invalid syntax in file 'c:\robotframework\extensions
\autoitlibrary\tes
ts\Calculator_Test_Cases.html' in table 'Setting': Creating an
instance of the t
est library 'AutoItLibrary' with arguments 'c:\robotframework
\extensions\autoitl
ibrary\tests\results', '10' and 'True' failed: com_error:
(-2147221164, 'Class n
ot registered', None, None)
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\robot\running\testlibraries.py",
line 155,
in _get_instance
return self._libcode(*self.positional_args, **self.named_args)
File "C:\Python27\lib\site-packages\AutoItLibrary\__init__.py", line
79, in __
init__
self._AutoIt = win32com.client.Dispatch("AutoItX3.Control")
File "C:\Python27\lib\site-packages\win32com\client\__init__.py",
line 95, in
Dispatch
dispatch, userName =
dynamic._GetGoodDispatchAndUserName(dispatch,userName,c
lsctx)
File "C:\Python27\lib\site-packages\win32com\client\dynamic.py",
line 104, in
_GetGoodDispatchAndUserName
return (_GetGoodDispatch(IDispatch, clsctx), userName)
File "C:\Python27\lib\site-packages\win32com\client\dynamic.py",
line 84, in _
GetGoodDispatch
IDispatch = pythoncom.CoCreateInstance(IDispatch, None, clsctx,
pythoncom.II
D_IDispatch)
AutoItLibrary Windows Calculator.Calculator Test Cases :: Tests the
AutoItL...
==============================================================================
Integer Addition :: Get "The Answer" by addition.
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
Integer Subtraction :: Get "The Answer" by subtraction.
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
Integer Multiplication :: Get "The Answer" by multiplication.
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
Integer Division :: Get "The Answer" by division.
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
Hex Addition :: Test Hex addition.
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
Hex Subtraction :: Test Hex subtraction.
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
Test Screen Capture On FAIL :: Test that a screenshot is taken and...
| FAIL |
Setup of the parent suite failed.
------------------------------------------------------------------------------
AutoItLibrary Windows Calculator.Calculator Test Cases :: Tests th...
| FAIL |
Suite setup failed:
No keyword with name 'Run' found.

Also suite teardown failed:
Several failures occurred:

1) No keyword with name 'Win Activate' found.

2) Non-existing variable '${MENUMAP}'.

3) No keyword with name 'Send' found.

4) No keyword with name 'Send' found.

5) No keyword with name 'Send' found.

6 critical tests, 0 passed, 6 failed
7 tests total, 0 passed, 7 failed
==============================================================================
AutoItLibrary Windows Calculator :: Post installation self-test fo...
| FAIL |
6 critical tests, 0 passed, 6 failed
7 tests total, 0 passed, 7 failed
==============================================================================
Output: c:\robotframework\extensions\autoitlibrary\tests\results
\output.xml
Report: c:\robotframework\extensions\autoitlibrary\tests\results
\report.html
Log: c:\robotframework\extensions\autoitlibrary\tests\results
\log.html
Press any key to continue . . .

C:\RobotFramework\Extensions\AutoItLibrary\tests>

Does anyone has any suggestions on how to fix it?

Thanks,
Eileen

Eileen Wei

unread,
Oct 8, 2010, 9:49:20 AM10/8/10
to robotframework-users
Note that I have installed AutoIt Library on my Win7 32bit and WinXP
machine and they both work fine. So it's 64bit that's causing the
problem. I would really appreciate any suggestion on how to get this
work on a 64bit Windows machine.

Thanks,
Eileen

Taylor, Martin

unread,
Oct 8, 2010, 11:53:48 AM10/8/10
to eileen...@gmail.com, robotframework-users
I won't get a chance to look at this until later next week. I do have a Win7 64-bit machine at work and thought I'd tested AutoIt there, but maybe I missed something.

Cheers,
Martin

> --
> You received this message because you are subscribed to the
> Google Groups "robotframework-users" group.
> To post to this group, send email to
> robotframe...@googlegroups.com.
> To unsubscribe from this group, send email to
> robotframework-u...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/robotframework-users?hl=en.
>
>

John Flower

unread,
Nov 25, 2010, 10:46:02 AM11/25/10
to robotframework-users
I have the same problem - has anyone found a solution yet?

Regards,

John

Eileen Wei

unread,
Nov 25, 2010, 11:17:36 AM11/25/10
to robotframework-users
This is because AutoIt COM is a 32bit COM object, so if you installed
64bit python and 64bit pywin32 extensions, they won't work on 32bit
COM. The solution is to install 32bit python and 32bit pywin32
extensions. It worked for me :)

Hope this helps,
Eileen

Taylor, Martin

unread,
Mar 24, 2011, 11:44:29 AM3/24/11
to eileen...@gmail.com, robotframework-users, Vos, Eric
I've tested the AutoIt installation and the supplied Robot Framework tests on Windows 7 Ultimate N 32-bit and 64-bit and it works fine. In the environment I use for such testing I have:

- 32-bit ActiveState Python 2.6.4.10
- UAC is turned off (if not this causes LOTS of headaches for automation)
- Firewall is turned off (not necessary for AutoIt and RF unless you invoke it remotely)

I don't have any other Win7 environments to test on and won't until at least mid-April. If anyone is still having trouble with AutoIt and Win7 please let me know how your Win7 version and configuration differs from mine as described above.

Thanks,
Martin

> -----Original Message-----
> From: robotframe...@googlegroups.com
> [mailto:robotframe...@googlegroups.com] On Behalf Of Eileen Wei

rajesh...@gmail.com

unread,
Jul 23, 2013, 2:56:56 PM7/23/13
to robotframe...@googlegroups.com, eileen...@gmail.com, Vos, Eric
Hi All,

I am using Python 2.7, 64 bit pywin32 in 64 bit windows 7. AutoIt libarary doesn't imports properly and gives this error when tried to import it

Traceback (most recent call last):
Creating an instance of the test library 'AutoItLibrary' with arguments '', '10' and 'True' failed: com_error: (-2147221164, 'Class not registered', None, None)
Traceback (most recent call last):
  File "C:\Python27\lib\site-packages\AutoItLibrary\__init__.py", line 79, in __init__
    self._AutoIt = win32com.client.Dispatch("AutoItX3.Control")
  File "C:\Python27\lib\site-packages\win32com\client\__init__.py", line 95, in Dispatch
    dispatch, userName = dynamic._GetGoodDispatchAndUserName(dispatch,userName,clsctx)
  File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 114, in _GetGoodDispatchAndUserName
    return (_GetGoodDispatch(IDispatch, clsctx), userName)
  File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 91, in _GetGoodDispatch
    IDispatch = pythoncom.CoCreateInstance(IDispatch, None, clsctx, pythoncom.IID_IDispatch)
  File "C:\Python27\lib\site-packages\robotide\spec\librarymanager.py", line 75, in _fetch_keywords
    return get_import_result(path, library_args)
  File "C:\Python27\lib\site-packages\robotide\spec\libraryfetcher.py", line 20, in get_import_result
    lib = TestLibrary(path, args)
  File "C:\Python27\lib\site-packages\robotide\lib\robot\running\testlibraries.py", line 41, in TestLibrary
    lib.create_handlers()
  File "C:\Python27\lib\site-packages\robotide\lib\robot\running\testlibraries.py", line 124, in create_handlers
    self._libinst = self.get_instance()
  File "C:\Python27\lib\site-packages\robotide\lib\robot\running\testlibraries.py", line 190, in get_instance
    self._libinst = self._get_instance()
  File "C:\Python27\lib\site-packages\robotide\lib\robot\running\testlibraries.py", line 198, in _get_instance
    self._raise_creating_instance_failed()
  File "C:\Python27\lib\site-packages\robotide\lib\robot\running\testlibraries.py", line 253, in _raise_creating_instance_failed
    "failed: %s\n%s" % (self.name, args, msg, details))


Is anyone aware how to cross this? Thanks in adv..

Wlad W.

unread,
Apr 30, 2014, 4:10:43 PM4/30/14
to robotframe...@googlegroups.com, eileen...@gmail.com, Vos, Eric
Hello guys,

i guess i have exactly the same (with slight differences :-) issue: 

Error in file 'c:\robot_fw_demo\simpletest\simpletest.txt': Initializing test library 'AutoItLibrary' with arguments [ c:\robot_fw_demo\simpletest | 30 | False ] failed: com_error: (-2147221164, 'Klasse nicht registriert', None, None) Traceback (most recent call last): File "C:\Python27\lib\site-packages\AutoItLibrary\__init__.py", line 79, in __init__ self._AutoIt = win32com.client.Dispatch("AutoItX3.Control") File "C:\Python27\lib\site-packages\win32com\client\__init__.py", line 95, in Dispatch dispatch, userName = dynamic._GetGoodDispatchAndUserName(dispatch,userName,clsctx) File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 114, in _GetGoodDispatchAndUserName return (_GetGoodDispatch(IDispatch, clsctx), userName) File "C:\Python27\lib\site-packages\win32com\client\dynamic.py", line 91, in _GetGoodDispatch IDispatch = pythoncom.CoCreateInstance(IDispatch, None, clsctx, pythoncom.IID_IDispatch) ////// END OF ERROR MESSAGE

"com_error: (-2147221164, 'Klasse nicht registriert', None, None)" = "com_error: (-2147221164, 'Class not registered', None, None)" just in German.

My setup is: win7 64 bit,  Python 2.7.6 64 bit, pywin32-218.win-amd64-py2.7, RF 2.8.4, AutoItLibrary 1.1
What i find strange is that when i run c:\robot_fw_demo\simpletest>pybot --version it says: Robot Framework 2.8.4 (Python 2.7.6 on win32). Why does it says "Python 2.76 on win32"? I have a  64 bit system.


Any idea if AutoItLibrary can be used with 64 bit Python on 64 bit win 7?

Thx in advance
Wlad

Wlad W.

unread,
Apr 30, 2014, 4:13:39 PM4/30/14
to robotframe...@googlegroups.com, eileen...@gmail.com, Vos, Eric
NOTE: tried with UAC + firewall turned off

Taylor, Martin

unread,
Apr 30, 2014, 4:15:08 PM4/30/14
to wagner.w...@gmail.com, robotframe...@googlegroups.com, eileen...@gmail.com, Vos, Eric

I’ve only ever tested AutoItLibrary with 32-bit Python. I run ActiveState’s 32-bit Python on a Win7 64-bit system. It works fine there. I doubt if the win32com.client.Dispatch(…) could be adapted to a 32-bit Python. Is there a particular reason that you MUST use 64-bit Python?

 

Thanks,

Martin

--

You received this message because you are subscribed to the Google Groups "robotframework-users" group.

To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-u...@googlegroups.com.


To post to this group, send email to robotframe...@googlegroups.com.

Wlad W.

unread,
Apr 30, 2014, 4:42:54 PM4/30/14
to robotframe...@googlegroups.com, wagner.w...@gmail.com, eileen...@gmail.com, Vos, Eric
I´m a noob in all that. I dont even know. I´m evaluating RF and what I´m looking for is a automation framework that will work fine with web applications especially in IE 10, Firefox and Chrome, SWT-based Eclipse RCP applications and in the long term also native iOS applications. Regarding that - may there be any disadvantages using 32 bit Python?

Thx,

Wlad

To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-users+unsub...@googlegroups.com.
To post to this group, send email to robotfram...@googlegroups.com.

Taylor, Martin

unread,
Apr 30, 2014, 5:10:05 PM4/30/14
to wagner.w...@gmail.com, robotframe...@googlegroups.com, eileen...@gmail.com

I’d say do your evaluation in 32-bit Python. We use both, but only use the 64-bit Python on a Mac OS X platform ‘cause we need to interface Python to Java using JPype, and Apple has forced Mac users to go with 64-bit Java. It really depends on what you’re testing. Our Windows apps are all 32-bit apps, so we have no need for 64-bit Python on Windows.

 

Cheers,

To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-u...@googlegroups.com.


To post to this group, send email to robotfram...@googlegroups.com.
Visit this group at http://groups.google.com/group/robotframework-users.
For more options, visit https://groups.google.com/d/optout.

--

You received this message because you are subscribed to the Google Groups "robotframework-users" group.

To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-u...@googlegroups.com.
To post to this group, send email to robotframe...@googlegroups.com.

CLAYTON

unread,
Apr 30, 2014, 6:53:39 PM4/30/14
to robotframe...@googlegroups.com
Dont forget autoit is a com library that registers itself into windows registry. On win7 theres two registries x86 and x64.. so therefore seems mandatory to use python x86 to access x86 registry as I assume autoit is x86

Wlad W.

unread,
May 5, 2014, 10:38:47 AM5/5/14
to robotframe...@googlegroups.com
Hi guys!

Have tried  ActivePython2.7.6 32-bit on another 64 bit win 7 machine. Seems to work fine so far.

Even my Internet Explorer (IE 10) issue from another post is gone now!

Thanks for recommending  ActiveState’s 32-bit Python!!!

Cheers,
Wlad


payal sarnot

unread,
Jul 21, 2017, 9:11:12 AM7/21/17
to robotframework-users
I tried downloading and installing ActivePython from http://www.download3k.com/Install-ActiveState-Software-Inc.-ActivePython-212303.html but still the tests fail with same error.

payal sarnot

unread,
Jul 21, 2017, 9:11:12 AM7/21/17
to robotframework-users
Can you please share the link from where you downloaded ActivePython?

Thanks.


On Monday, May 5, 2014 at 8:08:47 PM UTC+5:30, Tset Noitamotua wrote:

ams...@gmail.com

unread,
Aug 16, 2017, 3:01:51 PM8/16/17
to robotframework-users
Hello,
I had same issue.
I solved the problem by uninstalling pypiwin32 and installing pywin32. It absolutely takes pywin32 unstead of pypiwin32.
Thanks
Reply all
Reply to author
Forward
0 new messages