Jump to content
EduGeek EdSec 2026 is on Tuesday in Derby! Join us for a day of EdTech security focused talks, networking, and an evening social ×

Recommended Posts

Posted

Im baffled

im pritty sure im creating the msi properly because its 6 boxes to fill in

 

but the current script is

 

@echo off

echo installing Lanchishire Music Service

call .\Installer_files\setup.exe /S /v/qn

call .\Installer_files\player\setup.exe /S /v/qn

echo Finished

 

 

 

each line of the script works in command line but as a whole it doesn't

any ideas?

Posted

I am guessing as i dont know your system, but from what i can remember from my old Dos days the call command was used to insert another batch file script into a batch file.

It doesn't look from your script like you are calling another batch file and with it working from the commend line have you tried removing the call command?

 

:)

 

 

Im baffled

im pritty sure im creating the msi properly because its 6 boxes to fill in

 

but the current script is

 

@echo off

echo installing Lanchishire Music Service

call .\Installer_files\setup.exe /S /v/qn

call .\Installer_files\player\setup.exe /S /v/qn

echo Finished

 

 

 

each line of the script works in command line but as a whole it doesn't

any ideas?

Posted
Call as a command is fine, I'm more likely to think it can't find the path to the echo and call commands so you should specify them fully.
Posted (edited)

When you run this batch file, what folder are you starting it in?

 

Doing stuff like:

 

.\installer

 

is good - it makes the script easy to move to another folder - but assumes that the command prompt has started running in the right folder. If you're running this from a server then it won't - cmd won't start with a UNC as "current folder"

 

You can make it completely portable by using the string slicing batch commands to work out "where am I now" and append that to the .\installer but it's probably easier to just put the full path in the batch file for now (or code it in VBScript which can be started in a UNC location)

 

Just realised one other thing - if you're trying to include this in an MSI then the ".\" bit may well work - you're running in the same folder as the MSI - but those setup programs look suspiciously like ones which will themselves launch msiexec to run an MSI and then everything falls over because you can't launch an MSI from inside an MSI ...

 

You might find it easier to use the Windows Installer Wrapper Wizard

Edited by srochford
  • Thanks 1
Posted
Just realised one other thing - if you're trying to include this in an MSI then the ".\" bit may well work - you're running in the same folder as the MSI - but those setup programs look suspiciously like ones which will themselves launch msiexec to run an MSI and then everything falls over because you can't launch an MSI from inside an MSI ...

 

You might find it easier to use the Windows Installer Wrapper Wizard

 

Indeed the setup commands are nasty povvit Installshield setups that call MSIs... the WIWW didn't work with these for some reason... hence the script wrapping them up. Stu failed to mention that to create the MSI he is using WIWW to wrap the batch file.

 

If anybody knows an easy way to deploy the Lancashire Music Services Interactive Courses software we would be very grateful ;)

Posted
Indeed the setup commands are nasty povvit Installshield setups that call MSIs... the WIWW didn't work with these for some reason... hence the script wrapping them up. Stu failed to mention that to create the MSI he is using WIWW to wrap the batch file.

 

 

Can't believe I wrote the stuff about WIWW - of course it won't work because it's using an MSI to call an MSI ...

 

why not put this as a machine startup script with a "flag" check -

if exist "c:\program files\music\abc.exe" goto end
rem do stuff to install
:end

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



×
×
  • Create New...