AutoHotkey Community

It is currently May 26th, 2012, 3:20 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 414 posts ]  Go to page Previous  1 ... 11, 12, 13, 14, 15, 16, 17 ... 28  Next
Author Message
 Post subject: Error at line 0
PostPosted: March 8th, 2009, 6:35 am 
Offline

Joined: November 25th, 2006, 9:02 am
Posts: 13
Dear ladiko,
compiling with Compile_AHK I receive the "Succesfully compiled" message.
But when I try to run my compiled script, I obtain the following:

Quote:
Error at line 0.

Line Text:
[@\compilerZ@...
Error: This line does not contain a recognized action.


Same script compiled with AHKIconChanger works fine.
Any suggestion? Thanks.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: March 8th, 2009, 1:06 pm 
Offline

Joined: July 14th, 2006, 12:31 am
Posts: 290
Location: Berlin
compile it again with compile_ahk and post the resulting %temp%\AutoHotkey\Compiler\Compile_AHK.log


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: March 8th, 2009, 2:02 pm 
Offline

Joined: November 25th, 2006, 9:02 am
Posts: 13
Here's the file you requested:

Code:
* Set No_UPX option
FileDelete , C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\Upx.exe
# Set No_UPX option successfully

* Create resource file:
"C:\Program Files\AutoHotkey\Compiler\GoRC.exe" /r "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\VersionInfo.rc" >> "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\GoRC.log"

~~ GoRC Log Start ~~
GoRC.Exe Version 0.90.2 - Copyright Jeremy Gordon 1998/2006 - JG@JGnet.co.uk
Output file: C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\VersionInfo.res
~~ GoRC Log End ~~

# Resource file created successfully!


* Set Versioninfo (with ResHacker-fix for non-1033 systems):
"C:\Program Files\AutoHotkey\Compiler\ResHacker.exe" -script "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ChangeVersionInfo.script"

~~ Reshacker Log Start ~~
[08 mar 2009, 13.54.27]

[FileNames]
Exe=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
SaveAs=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
Log=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ResHacker.log

[Commands]
-delete Versioninfo , 1 , 1033
  Deleted: VERSIONINFO,1,1033
-addoverwrite "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\VersionInfo.res" , Versioninfo , 1 ,
  Modified: VERSIONINFO,1,1040

Commands completed
~~ Reshacker Log End ~~

# Set Versioninfo successfully!


* Replace icons:
"C:\Program Files\AutoHotkey\Compiler\ResHacker.exe" -script "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ChangeIcon.script"

~~ Reshacker Log Start ~~
[08 mar 2009, 13.54.28]

[FileNames]
Exe=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
SaveAs=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
Log=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ResHacker.log

[Commands]
-addoverwrite "E:\Design\_Soft\Script\Setup\ico\script.ico" , ICONGROUP,159,1033
  Modified: ICONGROUP,159,1033
-addoverwrite "E:\Design\_Soft\Script\Setup\ico\dot.ico" , ICONGROUP,206,1033
  Modified: ICONGROUP,206,1033
-addoverwrite "E:\Design\_Soft\Script\Setup\ico\dot.ico" , ICONGROUP,207,1033
  Modified: ICONGROUP,207,1033
-addoverwrite "E:\Design\_Soft\Script\Setup\ico\dot.ico" , ICONGROUP,208,1033
  Modified: ICONGROUP,208,1033

Commands completed
~~ Reshacker Log End ~~

# Icons replaced successfully!


* Extract Manifest from binary file:
"C:\Program Files\AutoHotkey\Compiler\ResHacker.exe" -script "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ExtractManifest.script"

~~ Reshacker Log Start ~~
[08 mar 2009, 13.54.28]

[FileNames]
Exe=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
SaveAs=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.manifest
Log=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ResHacker.log

[Commands]
-extract "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.manifest" , 24 , 1 , 1033
  Extracted: 24,1,1033

Commands completed
~~ Reshacker Log End ~~

# Manifest extracted successfully!


* Overwrite Manifest in binary file:
"C:\Program Files\AutoHotkey\Compiler\ResHacker.exe" -script "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\OverwriteManifest.script"

~~ Reshacker Log Start ~~
[08 mar 2009, 13.54.28]

[FileNames]
Exe=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
SaveAs=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.bin
Log=C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\ResHacker.log

[Commands]
-addoverwrite "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\AutoHotkeySC.manifest" , 24 , 1 , 1033
  Modified: 24,1,1033

Commands completed
~~ Reshacker Log End ~~

# Manifest overwritten successfully!


* Compile script:
"C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\Ahk2Exe.exe" /in "E:\Design\_Soft\Script\main.ahk" /out "E:\Design\_Soft\Script\Script.exe" /pass "pKB0ERUH7WL" /NoDecompile >> "C:\Users\Adm\AppData\Local\Temp\AutoHotkey\Compiler\Compile_AHK.log"
Successfully compiled: E:\Design\_Soft\Script\Script.exe

# Script Compiled successfully!

* Set new created date
FileSetTime , , E:\Design\_Soft\Script\Script.exe , C
# Set new created date successfully



Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: March 8th, 2009, 2:23 pm 
Offline

Joined: July 14th, 2006, 12:31 am
Posts: 290
Location: Berlin
yes, looks good ... so you only have to trial and error every option ^^

if you want, you can zip and send me the whole folder


Report this post
Top
 Profile  
Reply with quote  
PostPosted: March 24th, 2009, 8:07 pm 
Offline

Joined: August 25th, 2005, 9:40 pm
Posts: 129
is there a way to omit the addition of AutoHotkey icons to the compiled application ?
________
Drug Test Kit


Last edited by webber on March 11th, 2011, 12:32 am, edited 1 time in total.

Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: March 24th, 2009, 8:10 pm 
Offline

Joined: November 4th, 2008, 9:23 am
Posts: 1045
Yes, check the "delete" checkbox for the ones you don't want.

_________________
As always, if you have any further questions, don't hesitate to ask.

Add OOP to your scripts via the Class Library. Check out my scripts.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: May 4th, 2009, 2:35 am 
Offline

Joined: October 17th, 2006, 4:15 pm
Posts: 7502
Location: Australia
Selecting an 'Execution Level' other than 'none' inserts some XML into the manifest resource of the output executable. AutoHotkey_L and probably any other executable built with a recent version of Visual C++ already include the required key, with level="asInvoker". Compile_AHK inserts the XML anyway, and this invalidates the "side-by-side configuration", preventing the executable from launching.

Before the existing code:
Code:
   s_MANIFEST := s_LEFT
            . "<!-- Identify the application security requirements. -->`n"
            . "<!-- level can be ""asInvoker"" , ""highestAvailable"" , or ""requireAdministrator"" -->`n"
            . "   <trustInfo xmlns=""urn:schemas-microsoft-com:asm.v2"">`n"
            . "      <security>`n"
            . "         <requestedPrivileges>`n"
            . "            <requestedExecutionLevel`n"
            . "               level=""" . s_EX_LEVEL . """`n"
            . "               uiAccess=""false""`n"
            . "            />`n"
            . "         </requestedPrivileges>`n"
            . "      </security>`n"
            . "</trustInfo>`n"
            . s_RIGHT
...I would suggest inserting something simple, like:
Code:
local i_count
s_MANIFEST := RegExReplace(s_MANIFEST, "level\s*=\s*['""][^'""]*['""]", "level='" s_EX_LEVEL "'", i_count)
   if !i_count

See calculon's post for more information and screenshots of the problem.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 16th, 2009, 6:39 pm 
Offline

Joined: July 14th, 2006, 12:31 am
Posts: 290
Location: Berlin
aha AutoHotkey_L ... interesting!

ok i added your code snippet Lexikos to the my source code and according to NoDecimpile: if you use AutoHotkey_L simply dont use NoDecompile.

Update of 2009-06-16
    + Fixed: language.ini reworked
    + Fixed: error message if language.ini is missing
    + Changed: if the AutohotkeySC.bin already has a manifest with an execution level, it will be changed instead of adding a second one (AutoHotkey_L -> side-by-side error)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 17th, 2009, 11:45 am 
Offline

Joined: February 5th, 2007, 3:37 pm
Posts: 31
Thanks for your efforts on this compiler. I use it for all my scripts :)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 17th, 2009, 5:04 pm 
Offline

Joined: June 17th, 2009, 4:56 pm
Posts: 2
Location: United States - Iowa
Would it be possible to allow another file/executable to be packaged with the compiled AHK executable?

What I'm trying to do is use AHK to automate program installations. RealVNC is one example.

The problem is that I have to make sure the RealVNC executable is in the designated filepath/location before running the AHK compiled executable. It would be awesome to have the RealVNC executable packaged inside the AHK compiled executable.

I was thinking maybe the Resources section was for this, but I can't seem to get it to work that way.

Can someone fill me in on how to do this? Or if it is possible?

Thanks.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 17th, 2009, 5:19 pm 
Offline

Joined: July 14th, 2006, 12:31 am
Posts: 290
Location: Berlin
Use the FileInstall command: http://www.autohotkey.com/docs/commands/FileInstall.htm

The Compile_AHK_Setup is a ahk script that use FileInstall to install/extract Compile_AHK. Take a look at the source code: http://www.autohotkey.net/~ladiko/Compi ... _Setup.ahk

AnAHKUser wrote:
Thanks for your efforts on this compiler. I use it for all my scripts :)
Compile_AHK isn't a compiler - it's just a "wrapper" for Ahk2exe.exe to extend the possibilities.


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Suggestion..
PostPosted: June 29th, 2009, 2:54 am 
Offline

Joined: September 15th, 2006, 10:25 am
Posts: 567
This is a really wonderful project of AHK and is of much use.. Many thanks to Nick and Ladiko..

Just a quick suggestion.. it would be nice for the installation script to add a readme file in the install directory stating the latest version installed.. I had to update cause i did not know which version i was using ..

thanks a ton..

_________________
If i've seen further it is by standing on the shoulders of giants

my site | ~shajul | WYSIWYG BBCode Editor


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 29th, 2009, 6:47 am 
Offline

Joined: July 14th, 2006, 12:31 am
Posts: 290
Location: Berlin
point the mouse on the installer or the compile_ahk.exe and look for the version number. one is the ahk-version used for compiling and the other is the compile_ahk version.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 29th, 2009, 10:28 pm 
Offline

Joined: June 17th, 2009, 4:56 pm
Posts: 2
Location: United States - Iowa
ladiko wrote:
Use the FileInstall command: http://www.autohotkey.com/docs/commands/FileInstall.htm

The Compile_AHK_Setup is a ahk script that use FileInstall to install/extract Compile_AHK. Take a look at the source code: http://www.autohotkey.net/~ladiko/Compi ... _Setup.ahk

AnAHKUser wrote:
Thanks for your efforts on this compiler. I use it for all my scripts :)
Compile_AHK isn't a compiler - it's just a "wrapper" for Ahk2exe.exe to extend the possibilities.

After reading through that and seeing the examples in the source code it makes sense. Thank you.


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: July 5th, 2009, 9:24 am 
Offline

Joined: July 22nd, 2007, 3:18 pm
Posts: 86
I get this error message when i add something in the resource tab

Image

any solution for that?


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 414 posts ]  Go to page Previous  1 ... 11, 12, 13, 14, 15, 16, 17 ... 28  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: Google [Bot], Google Feedfetcher and 9 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group