Question on InstallTarget with /auto command line option

Anonymous
2005-04-04
2005-04-06
  • Anonymous - 2005-04-04

    Originally created by: Alexander Lokotkov

    Sorry, I am not sure that this is an appropriate forum for that kind of questions.

    I have the tnf-file containing the following (our target ID value replaced with XXXXX).

    [Targets]

    Target1=fwio.trg,XXXXX

    [Files]

    In order to run the InstallTarget silently, I issue the following command from the bat-file:

    "%CDSDIR%"\InstallTarget.exe d:\work\fwio\tsp\fwio.tnf /auto "%CDSDIR%\Targets\Fastwel"

    where %CDSDIR% is an environment variable pointing to installtarget.exe location. The fwio.trg is located in d:\work\fwio\tsp.

    But this command doesn't install our target ("%CDSDIR%\Targets\Fastwel" remains empty).

    Could anyone please suggest the correct way to silently run the InstallTarget utility (in particular, from installshield script)?

    Thanks in advance.

    Alexander Lokotkov

     
  • Sabine.Mack

    Sabine.Mack - 2005-04-06

    To use enviroment variables you need the InstallTarget.exe with version 1.1.0.0. It is part of the CoDeSys V2.3.4.1 setup.

    The options of InstallTarget are:

    <path installtarget-exe=""> "<path *.tnf="" info-file="">" /auto [<install directory="">]</install></path></path>

    If you want to use it in a Batch-File, this works:

    "%CDSDIR%\InstallTarget.exe" d:\work\fwio\tsp\fwio.tnf /auto %CDSDIR%\Targets\Fastwel

    (note the missing quotation marks)

    If you want to use it in an InstallShield script, this works:

    szCommand = '"' + TARGETDIR ^ 'InstallTarget.exe"';

    szCmdLine = '"' + szTNFFile + '" /auto ' + szInstallDir;

    if (LaunchAppAndWait (szCommand, szCmdLine, WAIT) < 0) then

    MessageBox(@ERROR_INSTALLTARGET, SEVERE);
    

    endif;

    I hope that helps,

    Sabine Mack

     
  • Anonymous - 2005-04-06

    Originally created by: Alexander Lokotkov

    Thanks for your help. It works perfectly.

     

Log in to post a comment.