Jump to content

Is it possible to ControlSend Shift to 1 app?


Recommended Posts

  • Moderators

Is it possible to ControlSend Shift to 1 app so that anything else running on the system is not effected?

I tried this but it failed :)

ControlSend($window, "", "", "{SHIFTDOWN}")
Try sending it to the control that requires it.

ControlSend($window, "", "ControlID/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.

Link to comment
Share on other sites

Per the helpfile and our mod, who posted right below me, you DO need to specify a control, if you are using 'CONTROL' send :(. If you just want to send a key to a window, such as a game, just use the SEND() function after you activate it with WinActivate()

You misunderstand. ControlSend() specifically allows you to send keystrokes to a window without specifying the control so you can just send them to a specified window, which doesn't have to be active (as it would have to for Send).

:)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

You misunderstand. ControlSend() specifically allows you to send keystrokes to a window without specifying the control so you can just send them to a specified window, which doesn't have to be active (as it would have to for Send).

:)

I'm easily one to admit that i'm wrong; from the wording of the help file, and the fact that the controlID is not marked as optional, I made that assertion. I do apologize that the information i portrayed was wrong. Post deleted :(

ControlSend ( "title", "text", controlID, "string" [, flag] )

led me to believe that it was required, and

ControlSend works in a similar way to Send but it can send key strokes directly to a window/control, rather than just to the active window.

Looked like a typo :D

However, perhaps he should just use the key type, instead of name, as smoke stated:

ControlSend($window, "", "", "+")

-_-------__--_-_-____---_-_--_-__-__-_ ^^€ñ†®øÞÿ ë×阮§ wï†høµ† ƒë@®, wï†høµ† †ïmë, @ñd wï†høµ† @ †ïmïdï†ÿ ƒø® !ïƒë. €×阮 ñø†, bµ† ïñ§†ë@d wï†hïñ, ñ@ÿ, †h®øµghøµ† †hë 맧ëñ§ë øƒ !ïƒë.

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...