cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
CChong
Level 11 Flexeran
Level 11 Flexeran

Update Status won´t recognized

Hi,
I want to update an application and I have trouble with the update status.
I start the setup to install the product version 1.0 of my application - successfully.
When I start my setup a second time the setup is in maintenace mode and it works correct.
Now I want to update my application with the version 1.0.01. The update works successfully to.
When I now start the setup again it has to go into the maintenace mode but it remains in the update mode.
Many thanks for help,
Imke
0 Kudos
(7) Replies
Arpe
Level 3

Which InstallShield tool are you using to create the update? This will help in troubleshooting the issue. Thank you.

Sincerely,

Arpe
InstallShield Technical Support
0 Kudos
CChong
Level 11 Flexeran
Level 11 Flexeran

Hi Arpe,

thanks for replying!
I use the InstallShield Developer 8 but I don´t work with the Update Service - sorry, I posted my message in the wrong forum.

I call OnResumeUIBefore in my script and put my function there. After running the update the script should call OnMaintUIBefore by starting the setup. I think I´ve to set a state for the product version but I can´t find out how to do this.

Imke
0 Kudos
Arpe
Level 3

Where are you running the Update setup from when you expect it to run in Maintenance Mode? Add/Remove Programs? Directly from setup.exe? From the Build -> Run menu in the Developer IDE? Please let me know. Thank you.

Sincerely,

Arpe
InstallShield Technical Support
0 Kudos
CChong
Level 11 Flexeran
Level 11 Flexeran

I run it from the setup.exe

Imke
0 Kudos
Arpe
Level 3

There is a default option in Developer that creates a minor upgrade for each build. I'm wondering if you built the setup after running the update, so when you run from setup.exe it runs in update mode instead of maintenance mode. As a test you can turn this option off and try the update build again. The setting can be found in the Upgrades view, when you select Upgrade Windows Installer Setup. The default selection is Prompt, select Disable and try again.

Sincerely,

Arpe
InstallShield Technical Support
0 Kudos
CChong
Level 11 Flexeran
Level 11 Flexeran

Hi Arpe,
I try to control the update by the script with the OnResumeUIBefore Event Handler and what I want to do is:

1. Start setup version 1.0 > Installation of version 1.0
2. Start setup version 1.0 > Maintenance Mode
3. Start setup version 1.0.1 > Update Mode

Now the state has to change that by starting setup version 1.0.1 a second time the setup goes into the

Maintenance Mode.


Here is a piece of code:


function OnResumeUIBefore()

number updateResult, nvResult, nvBuffer;
string testString, svResult, svSubDir, FOLDER, svPath, svReturnVal;

begin

if (Is(FILE_LOCKED, TARGETDIR ^ "cas.exe")) then

MessageBox ("Die Anwendung ist zur Zeit in Betrieb.\n"+
"Bitte beenden Sie vor der Deinstallation das Programm.", INFORMATION);
exit;

endif;

updateResult = UpdateExclusive();

switch (updateResult)

case -1001:
//bvCheck1 = FALSE;
bvCheck2 = FALSE;
bvCheck3 = TRUE; //Installation/Update

case -1002:
//bvCheck1 = FALSE;
bvCheck2 = TRUE;
bvCheck3 = FALSE;

if (LaunchAppAndWait (EXTRA, "" , NOWAIT) < 0) then
MessageBox (EXTRA + " kann nicht ausgeführt werden.", SEVERE);
endif;

abort;

endswitch;

if (bvCheck3 = TRUE) then //Installation/Update

if (XCopyFile (SRCDIR ^ "\xml.dll", "", INCLUDE_SUBDIR) < 0) then
MessageBox("Datei 'xml.dll' konnte nicht kopiert werden", SEVERE);
endif;
SetStatusWindow( 0, "" );
Enable( STATUSEX );
StatusUpdate( ON, 100 );

... XCopyFile ...

MessageBox ("Installation / Update ist beendet.",INFORMATION);

extraInstallations();

endif;

end;


Many Thanks for help,
Imke
0 Kudos
Arpe
Level 3

The code you enter in the OnResumeUIBefore will only be executed in the case of a minor upgrade. If the setup detects that it has been previously installed and isn't an upgrade it will enter OnMaintUIBefore. Did you try my previous suggestion of turning off the Update setting and rebuilding? I just want to make sure that this issue isn't related to that. Please let me know the results. Thank you.

Sincerely,

Arpe
InstallShield Technical Support
0 Kudos