this-is-me Posted August 27, 2004 Share Posted August 27, 2004 @jon, Any small reply on my last 2 posts? Who else would I be? Link to comment Share on other sites More sharing options...
Administrators Jon Posted August 27, 2004 Author Administrators Share Posted August 27, 2004 Is there a way to allow the onexit to be called while the current script is paused, but be ready to jump back in if break(0) is called inside of onexit? Also, what about the onpause? maybe? OnExit is already called on exit even if the script was paused. (Click pause, click exit, onexit runs) onpause would be difficult with the way that autoit currently works internally (when paused the script isn't processed at all) Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Link to comment Share on other sites More sharing options...
this-is-me Posted August 27, 2004 Share Posted August 27, 2004 What I meant is this: Allow onexit to be called as if it was _part_ of the _currently running_ action, but return to the currently running action if the onexit function was stopped with break(0). That is why I voted for a return statement that would allow the actual code in the onexit function to decide whether or not to exit the script at that time (like vb). I this way, if a user tried to exit a script, the script would be able to ask "Would you like to save first" [Yes] [No] [Cancel] If cancel was pressed, the actions of the script would return to execution as if an exit had never been attempted. Comprende? Who else would I be? Link to comment Share on other sites More sharing options...
Valik Posted August 27, 2004 Share Posted August 27, 2004 For me, that raises the question, why have the option to exit a script at all if the script writer can just say "No, you can't close me". But anyway, according to the description of how the event works, what you are asking for is a technical impossibility because there literally isn't anything to return to; the stacks are already popped so all the data is lost (With the exception of global data since that is the last stack that is popped off). Link to comment Share on other sites More sharing options...
this-is-me Posted August 27, 2004 Share Posted August 27, 2004 I am sorry, I don't understand the technical aspects of it. Please let me rephrase the question: Is there a way to "call" the exitfunc code as if it was called as a function from the current line of script? Who else would I be? Link to comment Share on other sites More sharing options...
Guest Guidosoft Posted August 28, 2004 Share Posted August 28, 2004 Farkle Link to comment Share on other sites More sharing options...
SoltrX Posted August 31, 2004 Share Posted August 31, 2004 WinSetTrans. Great Is it possible to extend this to the function SplashTextOn ? Perhaps with Opt("WinSetTrans", 170) for all Splash-messages ? Thanks for all SoltrX Link to comment Share on other sites More sharing options...
this-is-me Posted August 31, 2004 Share Posted August 31, 2004 (edited) That's simple. I do it now. SplashImageOn("Splash", @TempDir & "\image.jpg", 320, 240, @DesktopWidth, @DesktopHeight, 3);show offscreen WinSetTrans ("Splash", "", 0);make invisible WinMove("Splash", "", (@DesktopWidth / 2) - (320 / 2) , (@DesktopHeight / 2) - (240 / 2));move back on screen For $i = 0 To 254 Step 2;fade in Sleep(10) WinSetTrans ("Splash", "", $i) Next Sleep(3000);wait a few seconds For $i = 254 To 0 Step - 2;fade back out Sleep(10) WinSetTrans ("Splash", "", $i) Next Edited August 31, 2004 by this-is-me Who else would I be? Link to comment Share on other sites More sharing options...
Administrators Jon Posted September 4, 2004 Author Administrators Share Posted September 4, 2004 (edited) Updated:http://www.autoitscript.com/autoit3/files/unstable/autoit/- Added: Ping()- Changed: StringMid() the "count" parameter is now optional (assumes remainder of the string)- Fixed: ^ operator- Changed: "step" option added to PixelChecksum() Edited September 4, 2004 by Jon Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Link to comment Share on other sites More sharing options...
Developers Jos Posted September 4, 2004 Developers Share Posted September 4, 2004 Just tested the script that generates all config files to see if it picks up all updates and noticed that also PixelChecksum changed from: PixelChecksum ( left, top, right, bottom )to: PixelChecksum ( left, top, right, bottom [, step] ) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Holger Posted September 4, 2004 Share Posted September 4, 2004 @Jon: there is a bug with "StringMid"I tried that:$string = "c:\windows\notepad.exe" $mid = StringMid($string,4) $mid = StringMid($string,4,3)I always get the message: incorrect number of parameters in function call !!!I saw in the script.cpp:{"STRINGMID", &AutoIt_Script::F_StringMid, 3, 3},which seems not to be correct.Regards Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
Administrators Jon Posted September 4, 2004 Author Administrators Share Posted September 4, 2004 Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Link to comment Share on other sites More sharing options...
Holger Posted September 4, 2004 Share Posted September 4, 2004 Great now I can delete my old 'ping' call in some scripts and change it to an internal command Maybe CyberSlug could have a little problem with it, cause in the past he wanted it like, i.e.if you use: If ping("www.something.com",100) Then Msgbox(0,"..."successfull") Else Msgbox(0,"error",@error) EndIf But however, it works good for me Thanks Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
Administrators Jon Posted September 4, 2004 Author Administrators Share Posted September 4, 2004 Great now I can delete my old 'ping' call in some scripts and change it to an internal command Maybe CyberSlug could have a little problem with it, cause in the past he wanted it like, i.e.if you use: If ping("www.something.com",100) Then Msgbox(0,"..."successfull") Else Msgbox(0,"error",@error) EndIf But however, it works good for me Thanks Holger The code I have from you did actually set those values in vResult so I updated the docs - I didn't really change the code. Unless you resent it with some changes? Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Link to comment Share on other sites More sharing options...
Holger Posted September 4, 2004 Share Posted September 4, 2004 (edited) I take a look...Edit: cannot find the thing why and how...At first I used instead of "vResult"-setting -> "SetFuncErrorCode"...Ok, if I find something (which will not break existing scripts) I will tell you so maybe for one of a next publish we can build in. Thanks and regards HolgerEdit again: after thinking about I see no chance for it, so we let it like it is.The problem is to return something that is true or false.Cause here are 0 and greater true and <0 have to be false and that is not possible, thatswhy.So, no more discussion about it like my mother always said: "you must eat what is on the table" (don't know the correct translation from german you know) Upd maybe a change is needed Jon, I'll send you the stuff and changed docu in a few minutes, if you want it to change...Then it would react like at "DriveMapAdd" -> success: result >= 0 ; when the function fails (returns 0) @error contains extended information...1 = timeout 2 = unreachable 3 = bad destination 4 = other network errorSorry, I've looked in the source from the 29.07. and maybe I've send you the old stuff with the vResult instead now of SetFuncErrorCode :">I saw that cause I still had the "autoit3-special" with a prepublish of the ping-function... Edited September 4, 2004 by Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
Holger Posted September 4, 2004 Share Posted September 4, 2004 @Jon did you thought about my changes? Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
Administrators Jon Posted September 4, 2004 Author Administrators Share Posted September 4, 2004 I take a look... Edit: cannot find the thing why and how... At first I used instead of "vResult"-setting -> "SetFuncErrorCode"... Ok, if I find something (which will not break existing scripts) I will tell you so maybe for one of a next publish we can build in. Thanks and regards Holger Edit again: after thinking about I see no chance for it, so we let it like it is. The problem is to return something that is true or false. Cause here are 0 and greater true and <0 have to be false and that is not possible, thatswhy. So, no more discussion about it like my mother always said: "you must eat what is on the table" (don't know the correct translation from german you know) Upd maybe a change is needed Jon, I'll send you the stuff and changed docu in a few minutes, if you want it to change... Then it would react like at "DriveMapAdd" -> success: result >= 0 ; when the function fails (returns 0) @error contains extended information... 1 = timeout 2 = unreachable 3 = bad destination 4 = other network error Sorry, I've looked in the source from the 29.07. and maybe I've send you the old stuff with the vResult instead now of SetFuncErrorCode :"> I saw that cause I still had the "autoit3-special" with a prepublish of the ping-function... K, I'll change it to match that. Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Link to comment Share on other sites More sharing options...
this-is-me Posted September 5, 2004 Share Posted September 5, 2004 (edited) Where are the docs on the listview stuff? You said they weren't in there last time, but surely they should be in there this time...Remember? #28222 Edited September 5, 2004 by this-is-me Who else would I be? Link to comment Share on other sites More sharing options...
Administrators Jon Posted September 5, 2004 Author Administrators Share Posted September 5, 2004 Updated:http://www.autoitscript.com/autoit3/files/unstable/autoit/- Changed the return values for Ping()- Removed URLDownloadToFile()- Added HttpGet() and FtpGet() - both have a new option to force a cache reloadYou can actually use HttpGet() for both http/ftp, but if you want to specify a binary/ascii transfer type for FTP then you can use FtpGet() which has an extra option.I've also put instructions in the docs on how to use usernames/password with http/ftp commands (this actually worked before but was not documented)- Added HttpGetSize() (FtpGetSize isn't looking doable without IE5)I'm looking to add a HttpSetProxy() command next and possibly a FtpPut() Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Link to comment Share on other sites More sharing options...
Administrators Jon Posted September 5, 2004 Author Administrators Share Posted September 5, 2004 Where are the docs on the listview stuff? You said they weren't in there last time, but surely they should be in there this time... Remember? #28222 Seeing as so many people wanted it I've had zip feedback on this one - so i'll assume everyone likes the syntax and way I've done it and I'll document it as is (I just didn't want to have to redocument if it wasn't liked). Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ 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