go0b3r Posted June 2, 2007 Share Posted June 2, 2007 Hey, im trying to figure this out, can someone help me make a simple script that loops, i just need it to type 0-9 until i shut it off. I dont want it to go 1,2,3,4,5,6,7,8,9,0.. Id like it if it could be randomized? Link to comment Share on other sites More sharing options...
J0ker Posted June 2, 2007 Share Posted June 2, 2007 (edited) Look at Random() in the helpfile. While 1 $number = Random(0,10, 1) MsgBox(0,"",$number) Wend Edited June 2, 2007 by J0ker Link to comment Share on other sites More sharing options...
go0b3r Posted June 3, 2007 Author Share Posted June 3, 2007 Look at Random() in the helpfile. While 1 $number = Random(0,10, 1) MsgBox(0,"",$number) Wend How do i get it to pick 0-9 but not have a popup window, like if i open notepad while its on it should type 5,3,1,2,6,1,6,7,8,3, blah blah blah, with like a 4 second wait between number changes. Link to comment Share on other sites More sharing options...
narayanjr Posted June 3, 2007 Share Posted June 3, 2007 (edited) While 1 $number = Random(0,10, 1) Send($number) sleep(4000) Wend that should do it i think Edited June 3, 2007 by narayanjr Link to comment Share on other sites More sharing options...
Generator Posted June 3, 2007 Share Posted June 3, 2007 Example of Random Keyboard input, this should give you the idea. Note: Bad example of UBound #include<Array.au3> #include<Misc.au3> Global $KeyStroke, $UBound, $Value, $Dll $KeyStroke=_ArrayCreate("A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U") $UBound=UBound($KeyStroke,20) HotKeySet( "{ESC}","Quitscript") ToolTip( "Fun Begins"&@CRLF&"Press ESC to Exit",Default,Default,"Random KeyStroke",1,1) Sleep(1500) ToolTip("") While 1 $Dll=DllOpen("user32.dll") If _IsPressed($UBound, $Dllopen)Then RandomKeys() Else Sleep(1000) EndIf WEnd Func Quitscript() DllClose($Dll) Exit EndFunc Func RandomKeys() $Random=Random($UBound[0],$UBound[20],1) Send("$Random",1) EndFunc Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now