Sign in to follow this  
Followers 0
GizmoC

Basic question: How do I handle "AutoItX" objects in C#?

3 posts in this topic

Hello

Ok, I hope this isnt too silly.. but I am new to this.

int x = autoit.PixelGetColor(blah) works fine

But, in what object do I "save" the return for autoit.PixelSearch(blah) ?

As we know, PixelSearch returns an array. But, when I tried

int[] temp = autoit.PixelSearch(blah) didnt work

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Did you define the size of the int[] first?

you might try letting the language do the type cast for you like using a variable without a type.

Hello

Ok, I hope this isnt too silly.. but I am new to this.

int x = autoit.PixelGetColor(blah) works fine

But, in what object do I "save" the return for autoit.PixelSearch(blah) ?

As we know, PixelSearch returns an array. But, when I tried

int[] temp = autoit.PixelSearch(blah) didnt work

Edited by MrTWist

Share this post


Link to post
Share on other sites

Hello

Ok, I hope this isnt too silly.. but I am new to this.

int x = autoit.PixelGetColor(blah) works fine

But, in what object do I "save" the return for autoit.PixelSearch(blah) ?

As we know, PixelSearch returns an array. But, when I tried

int[] temp = autoit.PixelSearch(blah) didnt work

Return Value

Success: Returns decimal value of pixel's color.

Failure: Returns -1 if invalid coordinates.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0