Sign in to follow this  
Followers 0
zampoot

Error compiling au3 file using aut2exe

14 posts in this topic

Hello

I made some script in vbscript to automate the compilation for each au3 file located in some folder, the compilation goes fine when the au3 file name is written in English and does not contain any spaces. but I got some au3 file names which is non-english. Additionally when I tried to compile au3 file which it name contain space or non english using this command in cmd :

aut2exe /in "nfsdk demo.zip" /out zipped.exe

I used double quotes but that doesn't work

So how to compile any au3 file using aut2exe from command line whatever the au3 file name is(non english,contain spaces .....)

thanks in advance 

Share this post


Link to post
Share on other sites



Can you compile a .zip file?

Oooh sorry I meant  

"nfsdk demo.zip.au3"

Share this post


Link to post
Share on other sites

I'm not familiar with command line compiling, But I'd first check that it works without spaces in the path or filename.

Tested and working without spaces

Share this post


Link to post
Share on other sites

If question is solved, please mark an anserws as best one, so other users, can see that the problem is solved :)

and welcome to the forums :)

Share this post


Link to post
Share on other sites

 

Try wrapped in single quote...

'"nfsdk demo.zip.au3"'

Doubt that works in VBS as a single qoute means the rest of the line is treated as comment. :)

@Zampoot, show us the exact line you coded  in VBS.

Jos

1 person likes this

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

Something like this should work fine:

Set objShell = CreateObject("Wscript.Shell")
objShell.Run("""C:\Program Files (x86)\AutoIt3\aut2exe\aut2exe.exe"" /in ""t2 with space.au3"" /out ""t25 with space.au3""")

Jos

1 person likes this

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

I think he said that the problem was the space in the path name :)

Share this post


Link to post
Share on other sites

Thanks JohnOne and Jos

I have tried your suggestion,still not work for me

here is some of my code :

TargetPath = "some directory"
FileName = "any file name with spaces"
IconName = "some icon absolute path"
Comm = "cmd /c "  & TargetPath & "\" & "Aut2Exe.exe /in " & TargetPath & "\" & FileName & ".au3" & " /out " & TargetPath & "\" & FileName & ".exe" & " /icon " & IconName
Set objShell = CreateObject("Wscript.Shell")
objShell.Run(Comm)

I put Aut2Exe.exe in the same directory where the au3 files are located.... 
any way I made some stupid solution in my vbscript file by renaming any file contains spaces to another name, I just replaced the space by underscore then compile the file and after that get it back to it's original name (I told you it's stupid :D)

So still not solved right ?! 

Share this post


Link to post
Share on other sites

Here's the skinny.  Your files that have spaces... need to be "double" quoted.  That's all Jos was trying to demonstrate.  Your "TargetPath and "FileName" and "IconName" do not have double quotes.

TargetPath = """some directory"""
FileName = """any file name with spaces"""
IconName = """some icon absolute path"""

If not double quoted, then the spaces act as markers for the command line (different switches).

1 person likes this

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

So still not solved right ?! 

It will be when you follow the advise given in my previous post and repeated by SmOke_N. ;)

Jos


Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0