ahmeddzcom Posted December 2, 2014 Share Posted December 2, 2014 (edited) Hi Guys Plz i Need Two Command Run in Same Time (;~ 1 Don't Stop And ;~ 2 D'ont Stop) i need notify 2 separate things ;~ 1 While 1 SplashTextOn("", "1", 100, 80, 5, 5, 50, "", 20) Sleep(2000) SplashOff() ExitLoop WEnd ;~ 2 While 1 SplashTextOn("", "2", 100, 80, 105, 5, 50, "", 20) Sleep(2000) SplashOff() WEnd Tnx Edited December 2, 2014 by ahmeddzcom Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted December 2, 2014 Moderators Share Posted December 2, 2014 ahmeddzcom,You can only have one splash screen at any one time - so you cannot display both together. >Why do you need 2 splash screens? Are you trying to notify 2 separate things? If so then perhaps my Notify UDF might be useful - look in my sig for the link. M23 232showtime 1 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
BrewManNH Posted December 2, 2014 Share Posted December 2, 2014 BTW, your While loops aren't needed. You're not looping, so putting the commands into a loop makes no sense. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted December 2, 2014 Moderators Share Posted December 2, 2014 (edited) BTW, your While loops aren't needed. You're not looping, so putting the commands into a loop makes no sense. 2nd loop is Edit: This could be done like this: 1. Create a separate script that does the SplashText 2. Use Run + ScriptFullPath + AutoIt3ExecuteScript + ScriptPathName + any command lines you want to pass You could create hidden GUI control(s), use these controls to set a value that the other script could read. Then you could pass the GUI hwnd (as a number and convert to hwnd in the SplashText script), the control id number, and all the parameters that splashtext function accepts. In a loop, you could check to see if the value is set in the hwnd+controlid, if it is, run the splash text, if it isn't, close the splashtext with splashoff. Sounds harder than it would be. Edited December 2, 2014 by SmOke_N Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
ahmeddzcom Posted December 2, 2014 Author Share Posted December 2, 2014 You can only have one splash screen at any one time - so you cannot display both together. > BTW, your While loops aren't needed. You're not looping, so putting the commands into a loop makes no sense. 2nd loop is Tnx guys Link to comment Share on other sites More sharing options...
Gianni Posted December 3, 2014 Share Posted December 3, 2014 (edited) ... a little trick ... $code1 = "while 1" & @CRLF & "SplashTextOn('', '1', 100, 80, 5, 5, 50, '', 20)" & @CRLF & "sleep(2000)" & @CRLF & "SplashOff()" & @CRLF & "WEnd" $code2 = "while 1" & @CRLF & "SplashTextOn('', '2', 100, 80, 125, 5, 50, '', 20)" & @CRLF & "sleep(2000)" & @CRLF & "SplashOff()" & @CRLF & "WEnd" _ExecuteScript($code1, $code2) MsgBox(0, "Info", "the 2 Splash are running in 2 endless separate tasks") Exit Func _ExecuteScript($code1, $code2) Local $tmp1 = @TempDir & "\tempexec1.tmp" Local $tmp2 = @TempDir & "\tempexec2.tmp" Local $hwnd = FileOpen($tmp1, 26) FileWrite($hwnd, $code1) FileClose($hwnd) $hwnd = FileOpen($tmp2, 26) FileWrite($hwnd, $code2) FileClose($hwnd) $pid1 = Run('"' & @AutoItExe & '" /AutoIt3ExecuteScript "' & $tmp1 & '"') $pid2 = Run('"' & @AutoItExe & '" /AutoIt3ExecuteScript "' & $tmp2 & '"') EndFunc ;==>_ExecuteScript Edited December 3, 2014 by Chimp Chimp small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt.... Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted December 3, 2014 Moderators Share Posted December 3, 2014 I see Chimp understood what I was talking about. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
ahmeddzcom Posted December 3, 2014 Author Share Posted December 3, 2014 (edited) ... a little trick ... $code1 = "while 1" & @CRLF & "SplashTextOn('', '1', 100, 80, 5, 5, 50, '', 20)" & @CRLF & "sleep(2000)" & @CRLF & "SplashOff()" & @CRLF & "WEnd" $code2 = "while 1" & @CRLF & "SplashTextOn('', '2', 100, 80, 125, 5, 50, '', 20)" & @CRLF & "sleep(2000)" & @CRLF & "SplashOff()" & @CRLF & "WEnd" _ExecuteScript($code1, $code2) MsgBox(0, "Info", "the 2 Splash are running in 2 endless separate tasks") Exit Func _ExecuteScript($code1, $code2) Local $tmp1 = @TempDir & "\tempexec1.tmp" Local $tmp2 = @TempDir & "\tempexec2.tmp" Local $hwnd = FileOpen($tmp1, 26) FileWrite($hwnd, $code1) FileClose($hwnd) $hwnd = FileOpen($tmp2, 26) FileWrite($hwnd, $code2) FileClose($hwnd) $pid1 = Run('"' & @AutoItExe & '" /AutoIt3ExecuteScript "' & $tmp1 & '"') $pid2 = Run('"' & @AutoItExe & '" /AutoIt3ExecuteScript "' & $tmp2 & '"') EndFunc ;==>_ExecuteScript Yeaaa ... This . Tnx Chimp But not Run After Compile Edited December 3, 2014 by ahmeddzcom Link to comment Share on other sites More sharing options...
Bert Posted December 3, 2014 Share Posted December 3, 2014 (edited) would you be so kind show the script you are trying to compile? The ENTIRE script please? It could be anything that is causing your issue and at this point we can only guess. Edited December 3, 2014 by Bert The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Gianni Posted December 3, 2014 Share Posted December 3, 2014 (edited) I see Chimp understood what I was talking about. Edited December 3, 2014 by Chimp Chimp small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt.... Link to comment Share on other sites More sharing options...
TheSaint Posted December 3, 2014 Share Posted December 3, 2014 If it is only two splash screens you are concerned over, then simple updating the one splash screen at regular intervals, with either message, should be good enough. Using the Adlib functions (perhaps) or one main Loop, etc. Make sure brain is in gear before opening mouth! Remember, what is not said, can be just as important as what is said. Spoiler What is the Secret Key? Life is like a Donut If I put effort into communication, I expect you to read properly & fully, or just not comment. Ignoring those who try to divert conversation with irrelevancies. If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it. I'm only big and bad, to those who have an over-active imagination. I may have the Artistic Liesense to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage) 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