Indigo Rose Software

Go Back   Indigo Rose Software Forums > Old Versions > TrueUpdate 2.0

 
 
Thread Tools Display Modes
  #1  
Old 03-14-2005
Ninj Ninj is offline
Forum Member
 
Join Date: Jul 2004
Posts: 13
Executing TU client exe from the command line

Hi,

In TUv1 there is a command line option, /S:#, which can be used to run true update client through the command line where # signifies the screens that will be shown.

Is there any equivalent for this command line option in TUv2? The help file shows only 2 options, the /DATFILE:<<Filename>> and /T:<<FilePath>>.

thanks,

Ninj
  #2  
Old 03-14-2005
Steven Carr's Avatar
Steven Carr Steven Carr is offline
Indigo Rose Customer
 
Join Date: Jul 2001
Location: Sunshine Coast, Queensland, Australia
Posts: 139
You can parse the command line yourself.

I made it so that i have the option "/HIDE" on the command line to not show the screens unless there is an update available.

Then when the update.exe is called implictly I execute it with a /HIDE parameter and does not display unless an update is available. When it is called say from the menu option it has no additional parameter and displays all the screens.

Here are some sections of the Client Script (basically merged from the silent install example and the code that was already there)

Code:
g_SilentUntilUpdateAvailable = false;

for idx, sArg in _CommandLineArgs do

  if( sArg == "/HIDE" ) then
    g_SilentUntilUpdateAvailable = true;
  end 
	
end
followed by

Code:
if(g_SilentUntilUpdateAvailable) then

  -- Get the list of TrueUpdate Servers
  tableTrueUpdateServers = TrueUpdate.GetUpdateServerList();
  if(tableTrueUpdateServers) then

    -- Loop through the list of TrueUpdate Servers
    for index, ServerName in tableTrueUpdateServers do

      -- Attempt to download the server configuration files
      GotServerFiles = TrueUpdate.GetServerFile(ServerName, false);

      -- If the download was successful, run the server script
      if(GotServerFiles) then
        TrueUpdate.RunScript("Server Script");
        break;
      end
    end
  end

else

  if( not _ClientRestarted ) then
    Result = Screen.Show("Startup");
  end

  if(Screen.Show("Connect to Server") == SR_SUCCESS) then
    TrueUpdate.RunScript("Server Script");
  end
end
There is one additional area you may want to add in the Server script in the case of an error in the confuration. Basically is is along the lines of

Code:
if(not g_SilentUntilUpdateAvailable) then
  Screen.Show("Update Actions Failed");		
end
Of course there is nothing limiting the arguments you use or the effect they have. I just used this to emulate the way i used the command line argument /S:# from TU1.

Hope this helps

Last edited by Steven Carr; 03-14-2005 at 05:16 AM.
  #3  
Old 03-14-2005
Ninj Ninj is offline
Forum Member
 
Join Date: Jul 2004
Posts: 13
Hi Steven,

It does make a lot of sense. Thanks!
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Having an AM5 exe start automatically on a web server Larry Singer AutoPlay Media Studio 5.0 7 10-09-2005 09:16 PM
Multiple directory structures within Autoplay exe Phil Merry AutoPlay Media Studio 5.0 11 05-19-2004 06:51 AM
Run a VB exe File gauravbr Setup Factory 6.0 3 01-10-2004 07:07 AM
Updating the Client Update EXE nickw TrueUpdate 1.0 8 12-10-2003 02:46 PM
Citrix or thin client deployment Mhare AutoPlay Media Studio 4.0 2 09-24-2003 03:46 PM


All times are GMT -6. The time now is 05:38 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright © 2000 - 2009 Indigo Rose Corporation. All rights reserved.
Indigo Rose Software