serialzs Posted March 15, 2004 Share Posted March 15, 2004 @allAutoIt Software:can i do the window always on top?what is the Command for it?-=[serialzs]=- Link to comment Share on other sites More sharing options...
Noise Posted March 15, 2004 Share Posted March 15, 2004 The trick is to use WinWaitActive for windows to pop up and have focus (be the active window).for example:Run, c:\temp\install\setup.exe;WinWaitActive, Choose Setup Language, Select the languageSend, {ENTER};WinWait, Welcome, Welcome to the Setup program.WinActivate, Welcome, Welcome to the Setup program.Send, !n;Notice the bottom 3 lines. I wait for the window I want to exist. Then I activate the window. Then I send keys to that window. Link to comment Share on other sites More sharing options...
serialzs Posted May 14, 2004 Author Share Posted May 14, 2004 @allanyone know how to do it...FileRemoveDir, %alluserprofile%\\Test Dirwen i put this command it doesnt work!!! it is always Errolevel 1wat i done wrong???? -=[serialzs]=- Link to comment Share on other sites More sharing options...
edmoncu Posted May 14, 2004 Share Posted May 14, 2004 that command only removes directory with no files, if that folder has files or directories in it, like if you want the functionality of RD of winxp or deltree, then you have to invoke a filedelete first for that particular directory (or delete all the subdirectories of that folder first).otherwise, you could RunWait a batch file to run RD command on that folder. Link to comment Share on other sites More sharing options...
serialzs Posted June 11, 2004 Author Share Posted June 11, 2004 1st of all thanks for the guide... need help again... autoit CommandWINMOVEhow can i center the window???-=[serialzs]=- Link to comment Share on other sites More sharing options...
Strat79 Posted June 15, 2004 Share Posted June 15, 2004 as for deleting directories and sub directories, you don't have to delete all file first if you dont want, just have to add a flag at the end. Bascially if you add the 1 at the end it will work like deltree.DirRemove ( "path" [,recurse] )Parameterspath Path of the directory to remove. recurse [optional] Use this flag to specify if you want to delete sub-directories too. 0 = (default) do not remove files and sub-directories 1 = remove files and subdirectories (like the DOS DelTree command) Example; Delete C:\Test1 and all subdirs and filesDirRemove("C:\Test1", 1) Link to comment Share on other sites More sharing options...
Strat79 Posted June 15, 2004 Share Posted June 15, 2004 For the winmove, are you wanting to center a window in the current desktop? I always just guess about what center would be. If you really need absolute center look in the help file under window functions and look into WinGetPos and WinGetClientSize. it may give you some insight. Link to comment Share on other sites More sharing options...
Strat79 Posted June 15, 2004 Share Posted June 15, 2004 for you first question about always on top it is this.WinSetOnTop ( "title", "text", flag )Parameterstitle The title of the window to affect. text The text of the window to affect. flag Determines whether the window should have the "TOPMOST" flag set.1=set on top flag, 0 = remove on top flag Link to comment Share on other sites More sharing options...
Orochimaru Posted September 1, 2005 Share Posted September 1, 2005 Hey everyone, darn im soo tired i've been trying to find out how to make a dialog box by pressing a shortcutkey. After the dialog has poped up i wanted to type somthing and then click ok and then make it Sleep(3000) after that open notepad and make it Send w/e i typed. But ofcourse i havnt got to do that, thats why im here for help.I did that with a INput box here is the code:HotKeySet("{F5}", "Type")HotKeySet("{F8}", "Pause")HotKeySet("{F9}", "Quit")While 1Sleep(100)WendFunc Type()While 1$clip1 = InputBox("Message", "Enter/Paste text to Spam", "" )Run("C:\Program Files\Starcraft\Starcraft.exe")Sleep(700)$i=0DoSend("{Enter}") Send("" & $clip1) Send("{Enter}")until $i=10wendEndFuncFunc Quit()While 1Exit 0WendEndfuncFunc Pause()While1WendEndfuncBasically all that does is when i press F5 a inputbox pops up and what ever i type in it. Gets send to w/e window im on after its sleep time.So i wanted to do that with a Dialog box because i wanted to Send Profiles that are more then 1 line at once.This is what i have so far but it seems to make no sense what so ever:dim $clip1HotKeySet("{F7}", "Type")HotKeySet("{F9}", "Pause")Func Pause()While 1WendEndfuncfunc type()while 1$clip1 = Dialog BoxSleep(700)$i=0DoSend("{Enter}") Send("" & $clip1) Send("{Enter}")until $i=10wendEndFuncGUICreate("Type What You Want To Spam Below") ; will create a dialog box that when displayed is centeredGUISetState (@SW_SHOW) ; will display an empty dialog box$GUI_EVENT_CLOSE = "1"$nEdit = GUICtrlCreateEdit ("Type Here", 3,3,300,180)GUICtrlCreateButton ("Ok", 20,200,50)GUISetState ()for $n=1 to 5GUICtrlSetData ($nEdit,@CRLF & "line "& $n)next$EM_LINEINDEX = 0x00BB$EM_LINEFROMCHAR = 0x00C9Do $msg = GUIGetMsg() if $msg >0 then $n=GUICtrlSendMsg ($nEdit, $EM_LINEINDEX,-1,0) $nline=GUICtrlSendMsg( $nEdit, $EM_LINEFROMCHAR,$n,0) GUICtrlSetState ($nEdit,256) ; set focus MsgBox (0,"Currentline",$nLine) EndifUntil $msg = $GUI_EVENT_CLOSEAll this does is when i run it a Dialog box pops up right away and then when i press F7 it types random words or numbers...Also i didnt include#include gui.........au3.because it says "Error reading #include gui.........au3."Can anyone please look at these sources and see if they can help me, i really need it thank you for reading. 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