Developers Jos Posted January 28, 2009 Developers Share Posted January 28, 2009 This does mean that the stored source in the program resources is stripped of all its comments and unused Funcs and global variables. It also means that in case you obfuscate the source it will store that obfuscated source. When Obfuscator isn't run, it will still work as before soring just the original base script. Jos 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...
rover Posted January 28, 2009 Share Posted January 28, 2009 two methods of adding and extracting script resources on demand from exe uses Zedna's Resources.au3 UDF Method 1 - Manually add includes and script as resource and extract to folder of choice expandcollapse popup#AutoIt3Wrapper_UseUpx=n #AutoIt3Wrapper_Res_SaveSource=y #AutoIt3Wrapper_Res_File_Add=C:\Progra~1\AutoIt3\Include\GUIConstantsEX.au3, RCData, 1 #AutoIt3Wrapper_Res_File_Add=C:\Progra~1\AutoIt3\Include\Constants.au3, RCData, 2 #AutoIt3Wrapper_Res_File_Add=C:\Progra~1\AutoIt3\Include\WindowsConstants.au3, RCData, 3 #AutoIt3Wrapper_Res_File_Add=%scriptdir%\Resources.au3, RCData, 4 ;#AutoIt3Wrapper_Res_File_Add=%scriptdir%\%scriptfile%.au3, RCData, 5 #AutoIt3Wrapper_Run_After=C:\Progra~1\AutoIt3\Aut2Exe\upx.exe --best --compress-resources=0 "%out%" ;#AutoIt3Wrapper_Res_File_Add=%scriptdir%\%scriptfile%.au3, RCData, 1 ;is same as: ;#AutoIt3Wrapper_Res_SaveSource=y ;can also use Reshacker and names for resources instead of #1 etc. #include <GUIConstantsEX.au3> #include <Constants.au3> #include <WindowsConstants.au3> #include "Resources.au3" Opt('MustDeclareVars', 1) Example() Func Example() Local $sFile Local $aFiles[5][2] $aFiles[0][0] = "GUIConstantsEX.au3" $aFiles[0][1] = "#1" $aFiles[1][0] = "Constants.au3" $aFiles[1][1] = "#2" $aFiles[2][0] = "WindowsConstants.au3" $aFiles[2][1] = "#3" $aFiles[3][0] = "Resources.au3" $aFiles[3][1] = "#4" $aFiles[4][0] = StringReplace(@ScriptName, ".EXE", ".AU3") $aFiles[4][1] = "#999" Local $hGUI = GUICreate("Resources: Script and includes ", 400, 300) Local $cButton = GUICtrlCreateButton("Get Script", 20,60) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE GUIDelete() Exit Case $cButton; demo for convenience only. replace with command line option to extract resources If @Compiled Then $sFile = FileSelectFolder("Select destination for script files", @HomeDrive, 7, "", $hGUI) For $i = 0 To UBound($aFiles) -1 _ResourceSaveToFile($sFile & "\" & $aFiles[$i][0], $aFiles[$i][1], $RT_RCDATA, 0, 1) Next EndIf EndSwitch WEnd EndFunc Method 2 - Automatically add script and includes to archive stored as a resource create an external parsing and archiving script run by command line add wrapper line: #AutoIt3Wrapper_Run_Before=Parse %scriptdir%\%scriptfile%.au3 parse through your script and extract include names, get includes from folder and add with script to archive of your choice in script folder with same name as script. use #AutoIt3Wrapper_Run_After to delete temporary archive in scriptdir #AutoIt3Wrapper_Run_After=Del %scriptdir%\%scriptfile%.zip you only need to write a parsing/archiving script and you've got what you want expandcollapse popup#Region;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_UseUpx=n ;#AutoIt3Wrapper_Run_Before=Parse %scriptdir%\%scriptfile%.au3 #AutoIt3Wrapper_Res_File_Add=%scriptdir%\%scriptfile%.zip, RCData, 1 #AutoIt3Wrapper_Run_After=C:\Progra~1\AutoIt3\Aut2Exe\upx.exe --best --compress-resources=0 "%out%" ;#AutoIt3Wrapper_Run_After=Del %scriptdir%\%scriptfile%.zip #EndRegion;**** Directives created by AutoIt3Wrapper_GUI **** #include <GUIConstantsEX.au3> #include <Constants.au3> #include <WindowsConstants.au3> #include "Resources.au3" Opt('MustDeclareVars', 1) Example() Func Example() Local $sFile Local $hGUI = GUICreate("Resources: Script and includes ", 400, 300) Local $cButton = GUICtrlCreateButton("Get Script", 20,60) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE GUIDelete() Exit Case $cButton; demo for convenience only. replace with command line option to extract resources If @Compiled Then $sFile = FileSelectFolder("Select destination for script files", @HomeDrive, 7, "", $hGUI) _ResourceSaveToFile($sFile & "\" & StringReplace(@ScriptName, ".EXE", ".zip"), "#1", $RT_RCDATA, 0, 1) EndIf EndSwitch WEnd EndFunc I see fascists... Link to comment Share on other sites More sharing options...
rudi Posted January 30, 2009 Author Share Posted January 30, 2009 Hi Jos. I started working on a new release of AutoIt3Wrapper that will drop support for ANSI OSes like win98 since Autoit3 stopped supporting that too. I just made a small change to it that it will store the obfuscated source when you specify: #AutoIt3Wrapper_Res_SaveSource=y #AutoIt3Wrapper_Run_Obfuscator=y #Obfuscator_Parameters=/so Its available in the BETA download directory when you want to play with it... I had a look at this folder: http://www.autoitscript.com/autoit3/files/beta/autoit/ That's the wrong location, right? Thanks, Rudi. Earth is flat, pigs can fly, and Nuclear Power is SAFE! Link to comment Share on other sites More sharing options...
rudi Posted January 30, 2009 Author Share Posted January 30, 2009 This does mean that the stored source in the program resources is stripped of all its comments and unused Funcs and global variables.It also means that in case you obfuscate the source it will store that obfuscated source.When Obfuscator isn't run, it will still work as before soring just the original base script.JosCan you see any approach to preserve comments as well? I heavily make use of comments Regards, Rudi. Earth is flat, pigs can fly, and Nuclear Power is SAFE! Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted January 30, 2009 Moderators Share Posted January 30, 2009 Jos,Can I second Rudi's request? I would really like an option to keep comments in an Obfuscated /striponly script. I use comments a lot to help me remember what I was thinking when I go back to a script after a period of time - ah, the problems of getting old.....I know it is easy to put just the base script in the .exe with ResHacker, but the include files do change from time to time and it would be nice to have a record of what the various UDFs did for that particular script when it was compiled.Would it be very difficult? I am quite prepared to believe that it would be - but I am sure you could do it if you tried ;-)M23 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...
Developers Jos Posted January 30, 2009 Developers Share Posted January 30, 2009 The question is not really about it being easy or not, more what is the reason we have the /striponly option. The simple reason is to strip as much as possible for the source to keep the compiled exe as small as possible. Now the original idea of #AutoIt3Wrapper_Res_SaveSource was to save the base script in the resources which adds again some extra size to the target exe. So the question now is what it is we want to support here on top of what it supports now? Its now open for opinions / suggestions. (i will have a look at it all at the end of next week when I am back ) 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...
Zedna Posted January 30, 2009 Share Posted January 30, 2009 I can find some posts citeing Zedna's Resource UDF, but not the UDF itself: Where to get it? Is it command line capable, e.g. to use one run() call to save the code to <scriptname>.au3?Here is link to my resources UDFhttp://www.autoitscript.com/forum/index.php?showtopic=51103 Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Zedna Posted January 30, 2009 Share Posted January 30, 2009 Hi Jos.I had a look at this folder: http://www.autoitscript.com/autoit3/files/beta/autoit/That's the wrong location, right?Thanks, Rudi.http://www.autoitscript.com/autoit3/scite/..._SciTE4AutoIt3/ Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
trancexx Posted January 31, 2009 Share Posted January 31, 2009 (edited) The question is not really about it being easy or not, more what is the reason we have the /striponly option.The simple reason is to strip as much as possible for the source to keep the compiled exe as small as possible.Now the original idea of #AutoIt3Wrapper_Res_SaveSource was to save the base script in the resources which adds again some extra size to the target exe.So the question now is what it is we want to support here on top of what it supports now?Its now open for opinions / suggestions.(i will have a look at it all at the end of next week when I am back )I'm for additional option, something like #AutoIt3Wrapper_Res_SaveSource but with obfuscator's /striponly kind of behaviour.If someone wants to make a transparent application for any reason (obviously required by some) that could be the best way to do it.edit:I guess nothing new said there Edited January 31, 2009 by trancexx ♡♡♡ . eMyvnE Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted January 31, 2009 Moderators Share Posted January 31, 2009 Jos, I believe most AutoIt users have 2 reasons for Obfuscating their script (either or both could apply): 1. They want to make it as difficult as possible to read if someone tries to get at the source: -- They use the /Convert_ functions to make the villian's job as hard as possible. 2. They want to make the compiled .exe as small as possible: -- They use the /Strip_functions to get rid of unnecessary lines. However, from Rudi's question, and the subsequent posts, it appears that there might be a third reason which has only just come to light. There seem to be a number of users who would like to keep the source in the compiled .exe - this could be for commercial reasons (showing the client the source for confidence), wishing to have an additional backup method, and no doubt others I cannot think of at the moment. 3. These users are not overly concerned about security or size, but would like a "coder-friendly" record of the code included: -- They would like to use /SF and /SV on the include files, but leave the main script untouched (or at least with comments intact). As I stated in my earlier post, the include files do change from time to time and it would be nice to have a record of what the various UDFs did for that particular script when it was compiled. So, as one of this third group, I would appreciate a directive that allowed a "coder-friendly" source to be included. Perhaps a new parameter "/StripOnlyIncludes"? Thanks for having this discussion. M23 P.S. I have tried to do something like what I describe above using the current Obfuscator. Reading the Obfuscator Help file, I saw that you already have the #Obfuscator_On/Off directives. I tried to add them to my script (_Off after the include files and _On at the end of the script) to see if I could get what I outlined above, but Obfuscator stripped all the functions, whether in the includes or in my script! Have I misunderstood the syntax/behaviour of the _On/Off directives? 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...
rudi Posted February 2, 2009 Author Share Posted February 2, 2009 Hi.@Zedna: Thanks for the links.Jos,I believe most AutoIt users have 2 reasons for Obfuscating their script (either or both could apply):1. They want to make it as difficult as possible to read if someone tries to get at the source:-- They use the /Convert_ functions to make the villian's job as hard as possible.As stated, I also have (larger) scripts, that I want to be protected at some level.For others, that basically are not much more than I could do with the build in CMD file capabilities, I don't need to protect what I've written.2. They want to make the compiled .exe as small as possible:-- They use the /Strip_functions to get rid of unnecessary lines.I assume, that close to 100% of all autoit scripts are started from a local HDD or using a LAN link, at least 100MBit, and they are stored on disks with plenty of space (server or PC). So I can't see why the size should be an issue. Of course, it's nice to say: Look, what I'm doing with less of 1MB of Prog Size! But, IMHO, that's nice, not required (for most purposes).However, from Rudi's question, and the subsequent posts, it appears that there might be a third reason which has only just come to light. There seem to be a number of users who would like to keep the source in the compiled .exe - this could be for commercial reasons (showing the client the source for confidence), wishing to have an additional backup method, and no doubt others I cannot think of at the moment.3. These users are not overly concerned about security or size, but would like a "coder-friendly" record of the code included:Exactly. It's easy to write autoit EXE files. Some are just less than 20 lines, small scripts. I work in network environments for several customers. For easy use of such "small helper programs" I have a search path pointing to a network share, holding all these and other scripts (and tools). e.g. several robocopy jobs with validation of source and destination. These I left at (the ugly) CMD file versions so far...-- They would like to use /SF and /SV on the include files, but leave the main script untouched (or at least with comments intact). As I stated in my earlier post, the include files do change from time to time ...Or they are UDFs. UDFs sometimes are removed for certain reasons. (e.g. becoming obsolete, due to natively improved functions of autoit itself) So including such stuff would be perfect: Then it's possible to redesign a script, that was compiled with (now obsolete) UDFs, and that would have to be rewritten to meet new syntax rules.... and it would be nice to have a record of what the various UDFs did for that particular script when it was compiled.So, as one of this third group, I would appreciate a directive that allowed a "coder-friendly" source to be included. Perhaps a new parameter "/StripOnlyIncludes"?The best idea of course is to backup each and every source code including all the used native autoit includes and UDFs. But honestly: Real life often looks like different: "Oh, please, could you code .... for me? It takes you just a few minutes - please?". And - DING - , there is another script without source backup But the main reason asking for that feature is that customer, that want's to be able to retrieve the full source code from the EXE files. I'd like to "beautify" my CMD scripts by rewriting them in autoit, and to make them more user friendly. And, as a nice extra, I'll be able to use the better functionallity of Autoit, compared to CMD files.Regards, Rudi. Earth is flat, pigs can fly, and Nuclear Power is SAFE! Link to comment Share on other sites More sharing options...
Developers Jos Posted February 5, 2009 Developers Share Posted February 5, 2009 P.S. I have tried to do something like what I describe above using the current Obfuscator. Reading the Obfuscator Help file, I saw that you already have the #Obfuscator_On/Off directives. I tried to add them to my script (_Off after the include files and _On at the end of the script) to see if I could get what I outlined above, but Obfuscator stripped all the functions, whether in the includes or in my script! Have I misunderstood the syntax/behaviour of the _On/Off directives?The #Obfuscator_On/Off directives are created to stop the actual obfuscation for that part of the script to workaround obfuscation problems when using eval() or things like that. The stripping process will still be done.Jos 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...
Moderators Melba23 Posted February 5, 2009 Moderators Share Posted February 5, 2009 Jos, Thanks. M23 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...
Developers Jos Posted February 5, 2009 Developers Share Posted February 5, 2009 (edited) What about this "simpel" standalone option if you really want the script added fully without any stripping: I have a script here that will take the original script and expand it with the include files into a new single file script. Store it in the AutoIt3 program directory and compile it. Now add these lines to your script: #AutoIt3Wrapper_Run_Before=""%autoitdir%\Expanderscript.exe" "%in%" "Fullsource.au3"" If ($CmdLine[0] >= 1) And ($CmdLine[1] = "/source") Then FileInstall("FullSource.au3","Fullsource.au3") Jos EDIT: Added logic to remove comments at the end of an #Include record.ExpanderScript.au3 Edited February 6, 2009 by Jos 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...
Bert Posted February 5, 2009 Share Posted February 5, 2009 From what you are saying, would it not be easy to simply do something like what is done to debug to msgbox? In your case, he could context click on the icon in the system tray to click on a menu item. A window would be displayed showing the code in progress. It would slow it down, but he would see it. here is a real crude example, but you will get the idea of what I'm getting at. In this example, the script will wait for notepad to be active, then sent the word "text" to it. After that, you will see the script in a msgbox. Simply put, I have a variable being updated for each line ran. $g = "" Opt("WinTitleMatchMode", 2) $g = $g&@ScriptLineNumber & ': Opt("WinTitleMatchMode", 2)' & @crlf WinWaitActive("Notepad") $g = $g&@ScriptLineNumber & ': WinWaitActive("Notepad")' & @crlf sleep(1000) $g = $g&@ScriptLineNumber & ': sleep(1000)' & @crlf send("text") $g = $g&@ScriptLineNumber & ': send("text")' & @crlf MsgBox(0, "", $g) The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 6, 2009 Moderators Share Posted February 6, 2009 Jos,Just tried your Expanderscript. I did amend your additional script code slightly:#AutoIt3Wrapper_Run_Before=""%autoitdir%\Expanderscript.exe" "%in%" "Fullsource.au3"" If ($CmdLine[0] >= 1) And ($CmdLine[1] = "/source") Then FileInstall("FullSource.au3","Fullsource.au3") Exit EndIfThe results were:Basic .au3 script = 88,373 ------- Fullsource .au3 = 2,069,072 (Shows how much include files save!)Compiled .exe without Fullsource = 351,877 -------- with Fullsource "FileInstall"ed = 743,558 (both compressed with upx)My only negative comment is made very "tongue-in-cheek" - I am appreciative of all you have done so far and do not wish to appear ungrateful.Fullsource.au3 is exactly that - every single byte of every single .au3 file (source and includes). How difficult would it be to "/StripOnly" the includes beforehand? The result could perhaps be described as the Obfuscated file, but retaining the comments of the basic source script.As I said, please do not take this as a criticism - I am well aware that this is not your main effort. Thanks again for taking the time to produce anything at all.M23 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...
Zedna Posted February 6, 2009 Share Posted February 6, 2009 Fullsource.au3 is exactly that - every single byte of every single .au3 file (source and includes). How difficult would it be to "/StripOnly" the includes beforehand? The result could perhaps be described as the Obfuscated file, but retaining the comments of the basic source script.M23Yes I agree.This would be GREAT functionality. (/striponlyincludes) Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Developers Jos Posted February 6, 2009 Developers Share Posted February 6, 2009 How difficult would it be to "/StripOnly" the includes beforehand? The result could perhaps be described as the Obfuscated file, but retaining the comments of the basic source script.Its not trivial because Obfuscator just rips out anything that looks like a comment at this moment. All code that came from Tidy and handled the comment sections is not there anymore. I would have a closer look to see howmuch effort is involved in putting some of it back in to allow this option.As I said, please do not take this as a criticism - I am well aware that this is not your main effort. Thanks again for taking the time to produce anything at all.Don't need to worry about this being taken wrong. When I am not in agreement you will know soon enough. Jos 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...
rudi Posted February 6, 2009 Author Share Posted February 6, 2009 (edited) Hi Jos.Thanks, this looks perfect.For other interested, these are the easy steps to use this feature:1.) Save beta AutoIt3Wrapper.Exe to "@ProgramFilesDir\autoit3\scite\AutoIt3Wrapper\" (you might want to backup the original version first)2.) Download Jos' ExpanderScript.au3 3.) Complile it to @ProgramFilesDir\Autoit\ExpanderFile.exe (must be exactly this location)4.) Add these lines to your script:#AutoIt3Wrapper_Run_Before=""%autoitdir%\Expanderscript.exe" "%in%" "Fullsource.au3"" If ($CmdLine[0] >= 1) And ($CmdLine[1] = "/source") Then FileInstall("FullSource.au3","Fullsource.au3") Exit EndIf... or use something like this:; just to include some #include ... ;) #include <array.au3> ; lines to use the new feature, Jos coded: #AutoIt3Wrapper_Run_Before=""%autoitdir%\Expanderscript.exe" "%in%" "Fullsource.au3"" If ($CmdLine[0] >= 1) Then If ($CmdLine[1] = "/source") Then $SourceSave =StringTrimRight(@ScriptName, 4)& "_full_source.au3" FileInstall("FullSource.au3", $SourceSave) MsgBox(0, "Source code saved", "You will find the full source code with all #includes in" & @LF & _ $SourceSave) Exit Else ; maybe do further checks for "/h" "-help", ... MsgBox(0, "Get Source Code", "To save the original source code, start this program with parameter ""/source""." & @LF & _ "(Without the quotation marks)") Exit EndIf EndIf ; Your code starts here... MsgBox(0,"End","Program End.")@Jos: This fails, when the #include lines have a trailing comment, like#include <array.au3>; for _ArrayDisplay() #include <file.au3> ; for _FileReadToArray() Great new feature, thank you so much Regards, Rudi. Edited February 6, 2009 by rudi Earth is flat, pigs can fly, and Nuclear Power is SAFE! Link to comment Share on other sites More sharing options...
Developers Jos Posted February 6, 2009 Developers Share Posted February 6, 2009 I added an extra test to remove the comments at the end of a line. 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...
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