2

I am doing a POC on Sikuli, stuck with an issue using moveTo() method.

Error received: TypeError: moveTo(): 1st arg can't be coerced to org.sikuli.script.Location

All lines of code written were as per Sikuli tutorial on their website.

Not able to proceed further, any help asap will very much appreciated.

Following is the code:

region_1 = Region(110,320,99,23)
region_2.moveTo(region_1)

1 Answer 1

2

moveTo() method accepts location object as parameter.

This is a common mistake which happens while using Sikuli.

Try correcting your code to :

region_1 = Region(110,320,99,23)
location_1 = Location(x,y)
region_1.moveTo(location_1)

Refer to below url for more information on Sikuli Region:

http://doc.sikuli.org/region.html

Hope this helps.

1
  • Ohh I feel silly now. This works.
    – user12986
    Nov 16, 2015 at 5:41

Your Answer

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

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