zampoot Posted February 13, 2015 Share Posted February 13, 2015 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 Link to comment Share on other sites More sharing options...
JohnOne Posted February 13, 2015 Share Posted February 13, 2015 Can you compile a .zip file? zampoot 1 AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
zampoot Posted February 13, 2015 Author Share Posted February 13, 2015 Can you compile a .zip file? Oooh sorry I meant "nfsdk demo.zip.au3" Link to comment Share on other sites More sharing options...
JohnOne Posted February 13, 2015 Share Posted February 13, 2015 I'm not familiar with command line compiling, But I'd first check that it works without spaces in the path or filename. SorryButImaNewbie 1 AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
zampoot Posted February 13, 2015 Author Share Posted February 13, 2015 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 Link to comment Share on other sites More sharing options...
SorryButImaNewbie Posted February 13, 2015 Share Posted February 13, 2015 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 Link to comment Share on other sites More sharing options...
JohnOne Posted February 13, 2015 Share Posted February 13, 2015 Try wrapped in single quote... '"nfsdk demo.zip.au3"' AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Developers Jos Posted February 13, 2015 Developers Share Posted February 13, 2015 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 zampoot 1 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...
Developers Jos Posted February 13, 2015 Developers Share Posted February 13, 2015 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 zampoot 1 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...
SorryButImaNewbie Posted February 13, 2015 Share Posted February 13, 2015 I think he said that the problem was the space in the path name Link to comment Share on other sites More sharing options...
Developers Jos Posted February 13, 2015 Developers Share Posted February 13, 2015 I think he said that the problem was the space in the path name ..and your point is ...what? 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...
zampoot Posted February 14, 2015 Author Share Posted February 14, 2015 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 ) So still not solved right ?! Link to comment Share on other sites More sharing options...
Moderators Solution SmOke_N Posted February 14, 2015 Moderators Solution Share Posted February 14, 2015 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). zampoot 1 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. Link to comment Share on other sites More sharing options...
Developers Jos Posted February 14, 2015 Developers Share Posted February 14, 2015 So still not solved right ?! It will be when you follow the advise given in my previous post and repeated by SmOke_N. 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...
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