2

Got an error encountered "No keyword name" error in AutoIt Library Robot Framework. I installed the AutoIt Library by using pip install and it was successful. I tried to automate input text in the Open Dialog Window to upload some file using AutoIt Library, but it won't run the keyword from AutoIt, it shows No keyword name.

Here is my code :


*** Settings ***
Documentation   This is the script for Create Sales Visit Repository
Library     AutoItLibrary

*** Test Cases ***

Input Text
    Send        C:\Users\ruela\Documents\Different images format\BMP.bmp

====================================================================

Or anything that can suggest uploading a file using robot framework, it's ok, since the Choose File from selenium library cannot be used because of the open dialog window is not related to the web application.

9
  • 1
    Please show the code you have written
    – PDHide
    Commented Jan 24, 2020 at 8:41
  • *** Settings *** Documentation This is the script for Create Sales Visit Repository Library AutoItLibrary *** Test Cases *** Input Text Send C:\Users\ruela\Documents\Different images format\BMP.bmp
    – Ru eL
    Commented Jan 24, 2020 at 8:46
  • put that in your question please, whatever you have tried and what error you are getting
    – PDHide
    Commented Jan 24, 2020 at 8:47
  • Is your AutoItLibrary library in red.xml file?
    – pavelsaman
    Commented Jan 24, 2020 at 8:52
  • 2
    @Rule put your error message also. A proper stack trace could give more information than you could imagine. When ever you post debugging issues keep the error log, your code, and the expected output.
    – PDHide
    Commented Jan 24, 2020 at 15:16

1 Answer 1

2

Updated:

Even I faced the issue in recent versions of auto it and python:

Fix:

Check your python architecture ( is it 32 or 64 bit)

Just type python and see

enter image description here

For 32:

  1. Open cmd in "Run as administrator" mode
  2. run the command pip install robotframework-autoitlibrary
  3. Now clone the autoit library source code: nokia/robotframework-autoitlibrary.
  4. in the root directory run the below command: python setup.py install using cmd in admin mode

to navigate to root directory use the command pushd <filepath>' instead of cd ` if cd doesn't work in cmd opened in admin mode.

For 64:

  1. Open cmd in "Run as administrator" mode
  2. Now clone the autoit library source code: nokia/robotframework-autoitlibrary.
  3. in the root directory run the below command: python setup.py install using cmd in admin mode

to navigate to root directory use the command pushd <filepath>' instead of cd ` if cd doesn't work in cmd opened in admin mode.

You can install 64 bit python at:

Install 64-bit python , the default version is 32 so you ahve to downlad the 64 bit download file from: Python Releases for Windows

and download Windows x86-64 executable installer

and install it.

Check if 64 bit is installed:

enter image description here

Your code works fine for me :

Installed package :

Open cmd in "Run as administrator mode" and run below command

pip install robotframework-autoitlibrary

test.robot

*** Settings ***
Documentation   This is the script for Create Sales Visit Repository
Library     AutoItLibrary

*** Test Cases ***

Input Text
    Send        C:\\Users\\ruela\\Documents\\Different images format\\BMP.bmp

Ran as

robot test.robot
8
  • Hi, Thanks for this. By the way, what python version did you use? I used Python 37, but I still got the "No Keyword" error once I tried you script to run on my side. I have installed the autoitlibrary using pip and was successful. I'm not sure if this is related to the specific version of python.
    – Ru eL
    Commented Jan 28, 2020 at 2:48
  • @RueL see if only one python is installed or even python 2 is present in your system
    – PDHide
    Commented Jan 28, 2020 at 7:16
  • @RueL which ide are you using ? I ran it from cmd
    – PDHide
    Commented Jan 28, 2020 at 7:17
  • I ran also in cmd. I just copy your code and follow the command robot test.robot
    – Ru eL
    Commented Jan 28, 2020 at 8:40
  • @RueL sorry for the confusion , i was able to fix the issue . The issue was due to auotIt.dll was not registering automatically
    – PDHide
    Commented Mar 2, 2020 at 22:27

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.