z0mgItsJohn Posted April 23, 2008 Posted April 23, 2008 (edited) Hello AutoIt Peoples I Made A Handy Tool.. ~ Enjoy ~ Source : _Execute_Source_File.Au3 ;==================================================================================== ;= UFD Name............: _Execute_Source_File.Au3 ;= Function............: _Execute_Source_File ($AutoItExe, $Script_File, $Mode) ;= AutoIt Version......: 3.2.10.0 ;= Language............: English ;= Description.........: Lets You Run A Script File Without Compiling The Script ;= Author(s)...........: John O. Aka (John2006) And The (Help File) ;= Error Value.........: Returns 0 (@Error) ;= Succuess Value......: Returns 1 ;=================================================================================== ;= Notes...........................................................................: ;= $AutoItExe = @AutoItExe ;= $Mode = 0 ($Script_File Is The Same Drive As @ScriptDir .: Example : _Execute_Source_File (@AutoItExe, 'Test.Au3', '0') ;= $Mode = 1 ($Script_File Is Not The Same Drive As @ScriptDir .: Example : _Execute_Source_File (@AutoItExe, 'C:\Test.Au3', '1') ;= ................................................................................: ;==================================================================================== Func _Execute_Source_File ($AutoItExe, $Script_File, $Mode) If Not FileExists ($File) Then Return @Error EndIf If $Mode = ('0') Then Run ($AutoItExe & ' /AutoIt3ExecuteScript "' & @ScriptDir & '\' & $Script_File & '"') Return ('1') EndIf If $Mode = ('1') Then Run ($AutoItExe & ' /AutoIt3ExecuteScript "' & $Script_File & '"') Return ('1') EndIf EndFuncoÝ÷ Ù*.ÇÅ©©à.Ý«¢+Ø%¹±Õ±Ðí}áÕÑ}M½ÕÉ}¥±¹ÔÌÐì()}áÕÑ}M½ÕÉ}¥±¡Õѽ%Ñá°ÌäíQÍйÔÌÌäì°ÌäìÀÌäì¤)}áÕÑ}M½ÕÉ}¥±¡Õѽ%Ñá°ÌäíèÀäÈíQÍйÔÌÌäì°ÌäìÄÌäì¤ And Please Post Comments Bugs.. Etc ~ John Edited April 23, 2008 by John2006 Latest Projects :- New & Improved TCP Chat
karman Posted April 23, 2008 Posted April 23, 2008 i dont understand how u think when u submit something like this
Swift Posted April 23, 2008 Posted April 23, 2008 Dude leave him alone, any script is worth sharing. Thanks John!
JustinReno Posted April 23, 2008 Posted April 23, 2008 Why not just do this?: If @Compiled = 0 Then Run(@AutoItExe & " " & FileGetShortName(@ScriptFullPath)) If @Compiled = 1 Then Run(@ScriptFullPath) Its easy.
C2C Posted April 23, 2008 Posted April 23, 2008 Good old Justin. Beauty through simplicity. Top notch ----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win
weaponx Posted April 23, 2008 Posted April 23, 2008 Why not just do this?: If @Compiled = 0 Then Run(@AutoItExe & " " & FileGetShortName(@ScriptFullPath)) If @Compiled = 1 Then Run(@ScriptFullPath) Its easy. I think you missed something. The OP's script did not run itself.
i542 Posted April 23, 2008 Posted April 23, 2008 (edited) Nice! Might be useful for PPlayer (if Pascal didn't put "RIP" sign on it already...)i dont understand how u think when u submit something like thisyo, i dont understand whats ur krazi spek zo talk normal english, gotcha? Edited April 23, 2008 by i542 I can do signature me.
AutoProgramming Posted September 9, 2008 Posted September 9, 2008 Why not just do this?: If @Compiled = 0 Then Run(@AutoItExe & " " & FileGetShortName(@ScriptFullPath)) If @Compiled = 1 Then Run(@ScriptFullPath) Its easy. This, and the _Execute_Source_File() Won't work if the Computer running the Script doesn't have autoIt installed. But it's a nice function anyway ;D [u]My OpenSource Projects:[/u]- [BEEP] proMusiX- Search autorun.inf
z0mgItsJohn Posted September 9, 2008 Author Posted September 9, 2008 This, and the _Execute_Source_File() Won't work if the Computer running the Script doesn't have autoIt installed. But it's a nice function anyway ;DNot.. The Complete AutoIt Installed All You Need Is @AutoItExe On The Same Computer Latest Projects :- New & Improved TCP Chat
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