Sign in to follow this  
Followers 0
steelys

Question about controlsend function

6 posts in this topic

#1 ·  Posted (edited)

EDIT:

Okay i think i know how to do it.

If anyone wanna know, its

replacing string with {UP} or {DOWN}.

Question 1 :

How do i check Pixel Coord NOT of an active window. Like using control send but instead, it checks the pixel coord ?

Question 2 :

Is there anyway i could send keys to a window that is NOT active. Like using controlsend but not controlsend cause i cant seem to find that application's control id etc.

Thanks :)

Edited by steelys

Share this post


Link to post
Share on other sites



Did you try this:

ControlSend ( "title", "text", controlID , "{ENTER}" [, flag] )

ControlSend("MyTitle", "Some Text", 1111, "{ENTER}")

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Another question.

How do i check Pixel Coord NOT of an active window. Like using control send but instead, it checks the pixel coord ?

<{POST_SNAPBACK}>

I beilieve a window has to be at least activated to Pixel color or coord.

Opt("PixelCoordMode", 0)
WinActivate("MyWindow")
$Pix_Coord = PixelSearch(0, 55, 0, 55, 0xFE7B22); (Check X-Coord "0", and Y-Cood "55")
If Not @error Then
ControlSend("Some Title", "Some Text", 1111, $Pix_Coord[0] & "; " $Pix_Coord[1])
Else
MsgBox(0, "Error", "Pixel Colour not found!")
Endif

This gives you the coords of the pixel if it is found. This may not be what your looking for, but I tried to get as much out of your post as I could.

EDIT: If your trying to use Pixel Search as a Control then as far as I know this has not been done yet.

Edited by ronsrules

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

Thanks for all your help !! Really appreciate it..

Anyway,

Is there anyway i could send keys to a window that is NOT active. Like using controlsend but not controlsend cause i cant seem to find that application's control id etc.

Thanks :)

Share this post


Link to post
Share on other sites

Does the application have a ClassNameNN: ?


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

Nope it does not have a CLassNameNN nor an Control ID.

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