Quote:
Originally Posted by
Plan9 
VBS is designed to automate tasks too and can do everything you had listed - in fact your code is identical to VBS too (bar the missing is the object names):
Code:
Set objShell = WScript.CreateObject("WScript.Shell")
' ^ define once and then forget about it
objShell.Run("notepad.exe")
WScript.Sleep(1000)
objShell.Sendkeys("Hello, this is some text!")
Fair enough that AutoIt might be easier to learn amd/or have some more powerful APIs available (my exposure is only what's been posted in this thread so I'll have to take your word for that). But the example you've given wasn't really the best for comparison

It's hard to explain how powerful something is when you haven't used it. I suggest downloading it and giving it a spin so you understand how easy and fast it is to make applications in the language. AutoIt is really becoming a (single threaded) programming language of its own. I could paste an example here of things I have wrote in it to give you an idea of what can be done with it. Such as here is the source for my old byte patcher.
Code:
#cs ----------------------------------------------------------------------------
AutoIt Version: 3.3.6.1
Author: myName
Script Function:
Template AutoIt script.
#ce ----------------------------------------------------------------------------
; Script Start - Add your code below here
#NoTrayIcon
;~ Function Includes
#include <Array.au3>
#Include <String.au3>
#Include <File.au3>
;~ GUI Includes
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
;~ Check For File
If FileExists('Ebenezer.exe') = 0 Then
MsgBox(16, 'Error', 'Cannot Locate File')
Exit
EndIf
#Region
Opt('GUIOnEventMode', 1)
$Form1 = GUICreate('1298 SQL Login Changer', 298, 58)
$Group1 = GUICtrlCreateGroup('Login', 8, 0, 137, 49)
$Input1 = GUICtrlCreateInput('', 16, 16, 121, 21)
GUICtrlSetLimit(-1, 11)
GUICtrlCreateGroup('', -99, -99, 1, 1)
$Group2 = GUICtrlCreateGroup('Password', 152, 0, 137, 49)
$Input2 = GUICtrlCreateInput('', 160, 16, 121, 21)
GUICtrlSetLimit(-1, 15)
GUICtrlCreateGroup('', -99, -99, 1, 1)
GUISetState(@SW_SHOW)
GUISetOnEvent($GUI_EVENT_CLOSE, '_Write_Data')
#EndRegion
;~ Open File For Read/Write In Binary Mode
Global $File = FileOpen('Ebenezer.exe', 17)
;~ Login Pos Array
Global $Login[11]
$Login[0] = '25F0EC'
$Login[1] = '25F0ED'
$Login[2] = '25F0EE'
$Login[3] = '25F0EF'
$Login[4] = '25F0F0'
$Login[5] = '25F0F1'
$Login[6] = '25F0F2'
$Login[7] = '25F0F3'
$Login[8] = '25F0F4'
$Login[9] = '25F0F5'
$Login[10] = '25F0F6'
;~ Password Pos Array
Global $Pass[15]
$Pass[0] = '25F0DC'
$Pass[1] = '25F0DD'
$Pass[2] = '25F0DE'
$Pass[3] = '25F0DF'
$Pass[4] = '25F0E0'
$Pass[5] = '25F0E1'
$Pass[6] = '25F0E2'
$Pass[7] = '25F0E3'
$Pass[8] = '25F0E4'
$Pass[9] = '25F0E5'
$Pass[10] = '25F0E6'
$Pass[11] = '25F0E7'
$Pass[12] = '25F0E8'
$Pass[13] = '25F0E9'
$Pass[14] = '25F0EA'
;~ Get Current Info At Runtime
_Get_Data()
While 1 = 1
Sleep(1000)
WEnd
Func _Get_Data()
;----------------------------------------
; 11 Limit Login -
;----------------------------------------
Local $Array[1]
;~ Read Data From File
For $x = 1 To 11
FileSetPos($File, Dec($Login[$x - 1]), $FILE_BEGIN)
_ArrayAdd($Array, StringTrimLeft(FileRead($File, 1), 2))
Next
;~ Print Data In GUI
GUICtrlSetData($Input1, _HexToString($Array[1] & $Array[2] & $Array[3] & $Array[4] & $Array[5] & $Array[6] & $Array[7] & $Array[8] & $Array[9] & $Array[10] & $Array[11]))
;----------------------------------------
; 15 Limit Password -
;----------------------------------------
Local $Array[1]
;~ Read Data From File
For $x = 1 To 15
FileSetPos($File, Dec($Pass[$x - 1]), $FILE_BEGIN)
_ArrayAdd($Array, StringTrimLeft(FileRead($File, 1), 2))
Next
;~ Print Data In GUI
GUICtrlSetData($Input2, _HexToString($Array[1] & $Array[2] & $Array[3] & $Array[4] & $Array[5] & $Array[6] & $Array[7] & $Array[8] & $Array[9] & $Array[10] & $Array[11] & $Array[12] & $Array[13] & $Array[14] & $Array[15]))
EndFunc
Func _Write_Data()
;----------------------------------------
; 11 Limit Login -
;----------------------------------------
;~ Read Data From GUI
$Data = StringSplit(GUICtrlRead($Input1), '')
;~ Write New Data
For $x = 1 To $Data[0]
FileSetPos($File, Dec($Login[$x - 1]), $FILE_BEGIN)
FileWrite($File, $Data[$x])
Next
;~ Fill Leftovers With 00
If $Data[0] < 11 Then
For $z = $Data[0] + 1 To 11
FileSetPos($File, Dec($Login[$z - 1]), $FILE_BEGIN)
FileWrite($File, Chr(0))
Next
EndIf
;----------------------------------------
; 15 Limit Password -
;----------------------------------------
;~ Read Data From GUI
$Data = StringSplit(GUICtrlRead($Input2), '')
;~ Write New Data
For $x = 1 To $Data[0]
FileSetPos($File, Dec($Pass[$x - 1]), $FILE_BEGIN)
FileWrite($File, $Data[$x])
Next
;~ Fill Leftovers With 00
If $Data[0] < 15 Then
For $z = $Data[0] + 1 To 15
FileSetPos($File, Dec($Pass[$z - 1]), $FILE_BEGIN)
FileWrite($File, Chr(0))
Next
EndIf
;~ Exit
Exit
EndFunc
Like said, it's hard to explain how much can be done in it. If the language itself doesn't support what your looking to do, there is an entire database of UDF's you can use. Plus you can call functions in dynamic linked library's for even further capabilities (this is usually done for tasks that require speed). The possibilities are endless, plus VB Script doesn't support the same checks. If something goes horribly wrong during the mass deployment you're going to wish you had proper error handling to fall back on.