mentosan Posted March 9, 2009 Share Posted March 9, 2009 Hello people ! I would like to know if there is a method to wrap two *.exe files into single exe file. I'm not talking about building setup installation kit. I'm having 2 scripts, one script has a function to call the other script. After compilation two exe files will result, and I only want to have one exe file. Thank you Link to comment Share on other sites More sharing options...
Zedna Posted March 9, 2009 Share Posted March 9, 2009 Look at FileInstall() Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
mentosan Posted March 9, 2009 Author Share Posted March 9, 2009 In the Help Guide at fileinstall() function it is stated "Include and install a file with the compiled script". I don't want to install anything. Anyway I was checking the forum and I found something related i think, #AutoIt3Wrapper. Is this helpful ? Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted March 9, 2009 Share Posted March 9, 2009 In the Help Guide at fileinstall() function it is stated "Include and install a file with the compiled script". I don't want to install anything. Anyway I was checking the forum and I found something related i think, #AutoIt3Wrapper. Is this helpful ?Then what do you want to do? Do you want to include the second script as a resource and execute it? It would help if you could be more specific. .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface Link to comment Share on other sites More sharing options...
Zedna Posted March 9, 2009 Share Posted March 9, 2009 Another EXE files can't be executed directly from memory. They must be stored on disk first. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
/dev/null Posted March 9, 2009 Share Posted March 9, 2009 In the Help Guide at fileinstall() function it is stated "Include and install a file with the compiled script". I don't want to install anything. Anyway I was checking the forum and I found something related i think, #AutoIt3Wrapper. Is this helpful ?well it does not "install" anything. It just extracts the second EXE and stores it in the defined destination directory. If you call this "installing", then you can't use FileInstall().However, as already mentioned: You need to write the EXE to disk to be able to run it. So, FileInstall() looks like a pretty good choice ;-)CheersKurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
mentosan Posted March 9, 2009 Author Share Posted March 9, 2009 Then what do you want to do? Do you want to include the second script as a resource and execute it? YESIt just extracts the second EXE and stores it in the defined destination directory. I don't want this file to be seen. Link to comment Share on other sites More sharing options...
/dev/null Posted March 9, 2009 Share Posted March 9, 2009 I don't want this file to be seen.First: Why. Second: No way. __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
florisch Posted March 9, 2009 Share Posted March 9, 2009 I don't want this file to be seen.Delete it after it is finished. Or, if you have the source code of the second script, rework it so you can include its functionality. Link to comment Share on other sites More sharing options...
mentosan Posted March 9, 2009 Author Share Posted March 9, 2009 First: Why. Second: No way. &Delete it after it is finished. Or, if you have the source code of the second script, rework it so you can include its functionality.Unfortunatelly I don't have the source code. It's a program called tee.exe which helps you to have output from a terminal in a window and in the txt file at the same time, in real time. And my script (autoit script) will invoke this application from time to time. I want somehow to hide or to embed tee.exe in my autoit script. Link to comment Share on other sites More sharing options...
SpookMeister Posted March 9, 2009 Share Posted March 9, 2009 Not sure if this is what you are looking for... Or even if I "should" offer this info because you sound like your might be doing something a bit shady... but anyway: There is a way that you can run a second script file from the compiled executable of the first script... like so: $path = @ScriptDir & "\somescript.au3" $script = 'HotKeySet("^x", "Terminate")' & @CRLF & _ 'While 1' & @CRLF & _ 'Sleep(100)' & @CRLF & _ 'ToolTip("Press CTRL-X to stop this script")' & @CRLF & _ 'WEnd' & @CRLF & _ 'Func Terminate()' & @CRLF & _ 'Exit 0' & @CRLF & _ 'EndFunc' FileWrite($path, $script) HotKeySet("{ESC}", "Quit") $timer = TimerInit() $run_once = 1 $exit = 0 While 1 Sleep(100) If $run_once = 1 Then If TimerDiff($timer) > 3000 Then $run_once = 0 Run(@ScriptName & " /AutoIt3ExecuteScript somescript.au3", @ScriptDir) EndIf EndIf If $exit = 1 Then ExitLoop WEnd FileDelete($path) Func Quit() $exit = 1 EndFunc ;==>Quit Note: remember you have to compile the script before this will work [u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote] Link to comment Share on other sites More sharing options...
/dev/null Posted March 9, 2009 Share Posted March 9, 2009 Unfortunatelly I don't have the source code. It's a program called tee.exe which helps you to have output from a terminal in a window and in the txt file at the same time, in real time. And my script (autoit script) will invoke this application from time to time. I want somehow to hide or to embed tee.exe in my autoit script.O.K. so, where do you use tee.exe in your script and how? AND why is it you don't want to "show" the fact you are using it??? __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * 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