
azure
Active Members-
Posts
127 -
Joined
-
Last visited
Everything posted by azure
-
Windows XP Logon - Intelliremote
azure replied to Supraracer's topic in AutoIt General Help and Support
Rather than reboot, just have it logoff. If you have it automatically logging in, it should automatically log back in as long as the DefaultUserName, DefaultPassword, and AutoLogon keys are still set in your registry. -
Run exe in command line with environment variable
azure replied to pintas's topic in AutoIt General Help and Support
Oh... well no. you can change it to @SCRIPTDIR if prog.exe is in the same directory as your script. That's the working directory. I just use @SYSTEMDIR as a filler if the program I'm running is in the system path (accessible from anywhere). -
Maybe some sort of call to the video card driver or something. I know my video card auto detects if I have an external display connected vs. the built in LCD Screen. Good luck.
-
Quake3 doesn't run in a window. It's a full screen DirectX display. Don't think you can put a normal window on top of it like you're wanting. Maybe spitting GDI+ stuff to the screen?
-
no no.. he's trying to actually *MOVE* the icon locations on his desktop, not move the shortcuts themselves. Like find them and drag them to where he wants them.
-
How about something like running: TSKILL currentscript.exe It's a windows command to kill a process.
-
$strComputer = "." $objWMIService = ObjGet("winmgmts:\\" & $strComputer & "\root\cimv2") $colProcessList = $objWMIService.ExecQuery("Select * from Win32_Service") ConsoleWrite($colProcessList.Count & " services found.") For $objProcess In $colProcessList ConsoleWrite($objProcess.Name) Next
-
SciTE has context sensitive help. If you type Sleep(100) and put your mouse on the word "sleep" hit F1 and your help file should open with details on that command.
-
Can't find what? The help file? Start, Programs, AutoIt v3, autoIt Help File Or "C:\Program Files\AutoIt3\AutoIt.chm"
-
Add this to the end.. you left it out of the code you posted, but it's in your earlier responses. Func ExitProg() Exit 0 EndFunc
-
Run exe in command line with environment variable
azure replied to pintas's topic in AutoIt General Help and Support
Try this: Run(@COMSPEC & ' /c prog.exe copy "%appdata%\file.txt" -param',@SYSTEMDIR,@SW_HIDE) -
HotKeySet("F11","ExitScript") While 1 ;Put all your script stuff in here Sleep(100) WEnd Func ExitScript() Exit EndFunc
-
Use the help file please.
-
Please keep in the forum unless I ask you to PM me. Using the random function. Sleep(Random(10,100,1)*10)
-
Like this? ; Prompt the user to run the script - use a Yes/No prompt (4 - see help file) $answer = MsgBox(4, "AutoIt Example (English Only)", "Opening the leader project. Run?") ; Check the user's answer to the prompt (see the help file for MsgBox return values) ; If "No" was clicked (7) then exit the script If $answer = 7 Then MsgBox(4096, "AutoIt", "OK. Bye!") Exit EndIf ; Loop around until the user gives a valid "autoit" answer $bLoop = 1 While $bLoop = 1 $text = InputBox("AutoIt Example", "Please enter the program you want to run") If @error = 1 Then MsgBox(4096, "Error", "You pressed 'Cancel' - try again!") Else ; They clicked OK, but did they type the right thing? Select Case $text = "TFTB" ;Run the TFT Script, removed due to size $bLoop = 0 ; Exit the loop - ExitLoop would have been an alternative too :) Case $text = "MOZ" ;Do Something Else! $bLoop = 0 ; Exit the loop - ExitLoop would have been an alternative too :) Case Else MsgBox(4096, "Error", "You typed in the wrong thing - try again!") EndSelect EndIf WEnd ; Print the success message MsgBox(4096,"AutoIt Example", "You typed in the correct word! Congrats.") ; Finished!
-
Run exe in command line with environment variable
azure replied to pintas's topic in AutoIt General Help and Support
Double Quotes? like this? Run('prog.exe copy ""%appdata%\file.txt"" -param',@SYSTEMDIR,@SW_HIDE) -
Have you searched at all? Or have some code you tried to write? This may help you on your way. It's code that will give you information on any popup menus from right clicked system tray icons. Enumerate Tray Icon Menu Items
-
TRANSLATED.. so you can get more help. Hi folks, who can tell me where I find a documentation what options there are. Know only that NewConnection, system, application server, etc. Where can I find a detailed reference? $ g_oConnection = $LogonControl.NewConnection $g_oConnection.System = "R30", the name of your R / 3 system $g_oConnection.ApplicationServer = "hs2001"; Applic.Server of R / 3 system $g_oConnection.SystemNumber = 0; Number of your system R / 3 system ; *** User-specific data $g_oConnection.User = "myusername" $g_oConnection.Password = "secret" $g_oConnection.Client = "000" $g_oConnection.Language = "E" I know the keywords for the search does not. Gruß, Gecko
-
Hmm.. You can throw a sleep in between your run and mouseclick, since your winwait's don't seem to be working?
-
Yes... for one, you're not using [ autoit ] tags in your posts which makes reading code annoying. Another thing.. why have an icon file if you're not using it (trayseticon function) Another thing.. your startprog #2 function name is all wrong. You can't use spaces in function names. Another thing.. Your loops were all wacky.. You didn't have WEnd's where you had While's. You can't just start functions in the middle of loops too. Did you even check the errors you got when you tried compiling this? Try this: #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Version=Beta #AutoIt3Wrapper_icon=Cool-256x256.ico #AutoIt3Wrapper_Res_Comment=this is my first time making anything like taht #AutoIt3Wrapper_Res_Fileversion=0.0.1 #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** TraySetIcon("Cool-256x256.ico") #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 298, 226, 193, 115, $WS_POPUP, 0) $Pic1 = GUICtrlCreatePic(@WINDOWSDIR&"\Greenstone.bmp", 0, 0, 297, 225, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS)) GuiCtrlSetState(-1,$GUI_DISABLE) $START = GUICtrlCreateButton("START", 96, 64, 113, 49, 0) GUICtrlSetFont(-1, 24, 400, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetBkColor(-1, 0x808000) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $START GUIDelete($Form1) ExitLoop EndSwitch WEnd HotKeySet("{F4}", "ExitProg") ;;Sets F4 as a hotkey to exit the progam HotKeySet("{F5}", "StartProg") ;;Sets F5 as a hotkey to start the program HotKeySet("{F6}", "StartProg2") ;;Sets F6 as a hotkey to start the program 2# While 1 Sleep(100) Wend Func StartProg() Local $randomcoords[7][2] = [[217,65],[228,79],[173,81],[223,93],[190,110],[214,112],[255,138]] While 1 For $i = 0 To 7 MouseClick("left", 57, 45, 1) MouseClick("left", 127, 61, 1) $r = Random(0,6,1) MouseClick("left", $randomcoords[$r][0], $randomcoords[$r][1], 1) Next Sleep(500) WEnd EndFunc ;while if F6 was pressed than; ;Switch Func StartProg2() Local $randomcoords[7][2] = [[217,75],[228,79],[173,81],[223,93],[190,110],[214,112],[255,138]] While 1 For $i = 0 To 7 MouseClick("left", 57, 45, 1) MouseClick("left", 127, 61, 1) $r = Random(0,6,1) MouseClick("left", $randomcoords[$r][0], $randomcoords[$r][1], 1) Next Sleep(500) WEnd EndFunc
-
Oh. Thought it was more than one key. Dim $keys[1][3] = [[31,0,1]] That'd prolly do it.. or use the hotkey method posted by andybiochem.
-
RE: BrettF -> You can't parse ntuser.dat files like that.. they're all binary and stuff. Use these two UDF's: Privilege.au3 reg.au3 #include <reg.au3> _RegLoadHive("C:\Documents and Settings\Guest\ntuser.dat", "HKU\TempHive") RunWait("regedit.exe") _RegUnloadHive("HKU\TempHive") These mount the registry hives with advapi32.dll's RegLoadKey function. Enjoy.
-
Meh.. I was bored at work, waiting on other people to answer questions.. Gives me something to do.. I'm still learning AutoIT, so it's good for me.
-
TraySetIcon("shell32.dll",246) #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 298, 226, 193, 115, $WS_POPUP, 0) $Pic1 = GUICtrlCreatePic(@WINDOWSDIR&"\Greenstone.bmp", 0, 0, 297, 225, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS)) GuiCtrlSetState(-1,$GUI_DISABLE) $START = GUICtrlCreateButton("START", 96, 64, 113, 49, 0) GUICtrlSetFont(-1, 24, 400, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0xFFFFFF) GUICtrlSetBkColor(-1, 0x808000) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $START GUIDelete($Form1) ExitLoop EndSwitch WEnd HotKeySet("{F4}", "ExitProg") ;;Sets F4 as a hotkey to exit the progam HotKeySet("{F5}", "StartProg") ;;Sets F5 as a hotkey to start the program While 1 Sleep(100) Wend Func StartProg() Local $randomcoords[7][2] = [[217,65],[228,79],[173,81],[223,93],[190,110],[214,112],[255,138]] While 1 For $i = 0 To 7 MouseClick("left", 57, 45, 1) MouseClick("left", 127, 61, 1) $r = Random(0,6,1) MouseClick("left", $randomcoords[$r][0], $randomcoords[$r][1], 1) Next Sleep(500) WEnd EndFunc Func ExitProg() Exit 0 EndFunc