0
votes

I have to install on several machines 3 .exe that needed to be installed with correct order. To do that I created a .bat file to install then.

Start /wait %CD%\x.exe /q
Start /wait %CD%\y.exe /q
Start /wait %CD%\z.exe /q

If I copy the folder and install on the target machines it works. But I want to create a self extracting exe that have the .bat and the 3 .exe.

I'm trying with IExpress 2 but, when i run the .exe created by IExpress i always have the error "windows cannot find the ...file path". Why is %CD% not working? Do I need to change the path to the 3 .exe?

4
You mean you want an installer or a self extracting exe? Try removing the %CD%, it should default to current directory anyways. - Bali C
self extracting exe. I tried without %CD%, and didn’t worked. - António
Try using 7-Zip or WinZip self extracting exe function, that should work. - Bali C
To accomplish this in past I have used 7zip for all the heavy lifting (compressing the actual content AKA the big ZIP), then I use Iexpress to package up 7z.exe redist and the zip file.. then the cabinet maker script simply calls 7zip to extract the big file, and launch custom installer. This is because iexpress.exe is lousy when it comes to custom configurations.. so I just use it for the easy manifest and elevation stuff and let a real zip tool do the real work - nothingisnecessary

4 Answers

2
votes

This problem can be solved by both:

  • checking "use long file names"
  • saving your batch file with a .cmd extension instead of a .bat (IExpress has an option for using long file names, but it is ignored if you have a .bat file)

Source: http://knowciscostuff.wordpress.com/2012/06/15/iexpress-tool-on-windows-to-create-self-extracting-exe/

2
votes

On the options, select "Store files using Long File Name inside Package" to store the files in full names.

0
votes

The problem was the long names of the files. The file's name can't over 8 characters.

I just change the files names and it worked.

0
votes

The real solution to this specific problen is to check the option "Store files using Long File Name inside Package" in the window "Package Name and Options".