Jump to content

First Time Writer help please...


 Share

Recommended Posts

Hi,

I am a First time Writter on Macro Script using Auto it. I hit a Dead Rock, I trying to make it press "TAB" key by itself. Following is what I tried in the script and none worked can anyone tell me how should I wrote to get the macros to press "TAB" Key?

Send("{TAB 1}")

Send({TAB})

Send{TAB}

Send("TAB")

can someone teach me how to type it correctly? Thank You.

Sincerely,

Cig

Link to comment
Share on other sites

  • Moderators

Send('{TAB}')
Make sure the area you want to send it to has focus.

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

  • Moderators

Send("{TAB}")

I tried that one too forgot to type it in...

Send('{TAB}')

this one I need to try... haven't try this

It's going to give you the same results with a single quote as a double quote, it's just a habbit of mine to use single quotes. Send{"{TAB 1}") works also... But as I said, you "must" make sure the window you want to send it to has focus, or you won't see it happening... If it is a control you want to send it to or a specific window and now control, then you could do:
ControlSend('Window Name', '', 'Control ID', "{TAB}")
Or
ControlSend('Window Name', '', '', "{TAB}")

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

It's going to give you the same results with a single quote as a double quote, it's just a habbit of mine to use single quotes. Send{"{TAB 1}") works also... But as I said, you "must" make sure the window you want to send it to has focus, or you won't see it happening... If it is a control you want to send it to or a specific window and now control, then you could do:

ControlSend('Window Name', '', 'Control ID', "{TAB}")
Or
ControlSend('Window Name', '', '', "{TAB}")

Arrr.. I see... sorry first time Writter what's a "control ID"?

Link to comment
Share on other sites

ControlSend('Window Name', '', '', "{TAB}")

Tried that with the window name, but it still doesn't work I actually tested in Notepad and it works. Can I ask what did I do wrong?

Link to comment
Share on other sites

Welcome to the forums!

Your window has to be active in order for that Send function to work as planned.

Please read the help file and look up the Send, ControlSend, and WinActivate functions.

Get the full AutoIt Install, and run the AutoIt Window Info Tool (Au3Info.exe)

Select your game window and move the mouse around to see if the tool identifies any controls you can interact with.

Good luck!

[font="Tahoma"]"Tougher than the toughies and smarter than the smarties"[/font]

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...