Jump to content

VBS to Autoit3


Bean07
 Share

Recommended Posts

A line by line conversion

;Set wshshell = wscript.CreateObject("WScript.Shell")
;Unnecessary as AutoIt has a built-In function to send kestrokes without instantiating a COM object
;IID = InputBox("IID")
$IID = InputBox("","IID")
;wscript.sleep 1000
Sleep(1000)
;wshshell.sendkeys IID
Send($IID)

...however, I don't see the point of this demo?  Prompt for keys, just to send them again?

I assume you have bigger things in mind, so you might learn something more meaningful if you ask for pointers on how to accomplish what you want --end state...the more specific the better.

Also, don't expect the members here (myself included) to just spew out a script for you.  This one was simple enough to convert, but don't be surprised if you are asked to show some initiative in the future.  Your help file and google is your friend.  Notice how similar the commands/context were to convert your code; that information could have easily been found in the help file or searching otherwise.

Good luck and let us know when you get stuck.

Edited by spudw2k
Link to comment
Share on other sites

On 11/1/2017 at 2:48 PM, spudw2k said:

A line by line conversion

;Set wshshell = wscript.CreateObject("WScript.Shell")
;Unnecessary as AutoIt has a built-In function to send kestrokes without instantiating a COM object
;IID = InputBox("IID")
$IID = InputBox("","IID")
;wscript.sleep 1000
Sleep(1000)
;wshshell.sendkeys IID
Send($IID)

...however, I don't see the point of this demo?  Prompt for keys, just to send them again?

I assume you have bigger things in mind, so you might learn something more meaningful if you ask for pointers on how to accomplish what you want --end state...the more specific the better.

Also, don't expect the members here (myself included) to just spew out a script for you.  This one was simple enough to convert, but don't be surprised if you are asked to show some initiative in the future.  Your help file and google is your friend.  Notice how similar the commands/context were to convert your code; that information could have easily been found in the help file or searching otherwise.

Good luck and let us know when you get stuck.

Thank you! :D its worked

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