cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
dinesh_redhawk
Level 6

How to trigger forced Installation failure [Error.from Suite Installer

Hello Friends,

In the suite installer how to raise forced Installation failure or error.
I want the behavior something like "abort" or "return ERROR_INSTALL_FAILURE;"

Is there any thing like that? I want to show the Installation interrupted screen whenever any of my condition fails:

Please suggest.

Thanks
Labels (1)
0 Kudos
(6) Replies
rguggisberg
Level 13

You can force an error by attempting to execute a file that will not be found.

Events - Actions - New Exe - File [SETUPSUPPORTDIR]\SpecifyaFileThatWillNotBeFound.exe
Default Response - Abort
Then add that to Events where needed with the desired conditions.
0 Kudos
dinesh_redhawk
Level 6

rguggisberg wrote:
You can force an error by attempting to execute a file that will not be found.

Events - Actions - New Exe - File [SETUPSUPPORTDIR]\SpecifyaFileThatWillNotBeFound.exe
Default Response - Abort
Then add that to Events where needed with the desired conditions.


Hi rguggisberg,

Thanks for your response.
I am little confused. can u elaborate a little bit.
For ex: my situation is, in case if i find RAM is not sufficient from Installscript, i have to stop the installation by showing the screen Installation has interrupted. How can i do this as per you?
0 Kudos
Not applicable

If you're happy to do the check right at the start of a suite install and you don't need user interaction, you can author an "Exit Condition". This does a check, displays a warning message and then immediately exits.

Exit conditions can be created in the General Information section of a suite project.
0 Kudos
dinesh_redhawk
Level 6

Hysteresis wrote:
If you're happy to do the check right at the start of a suite install and you don't need user interaction, you can author an "Exit Condition". This does a check, displays a warning message and then immediately exits.

Exit conditions can be created in the General Information section of a suite project.


Thanks Hysteresis,
But exit conditions doesnt fit my requirement. Please dont go by my previous example of RAM checking.
There are some more conditions in between the installation sequence, where i need to check something and stop the installation by showing the Installation Failure screen.

Any ideas?

Thanks.
0 Kudos
Not applicable

dinesh_redhawk wrote:
Thanks Hysteresis,
But exit conditions doesnt fit my requirement. Please dont go by my previous example of RAM checking.
There are some more conditions in between the installation sequence, where i need to check something and stop the installation by showing the Installation Failure screen.

Any ideas?

Thanks.


I think you're going to need to give more detail then if your example isn't relevant. If you're still referring to suite installers then you could run your check, set a suite property to some value as a result of that check, pop-up a secondary window with you error message based on the property setting and finally terminate the installation by making the Installation complete the next wizard page displayed.

If you don't fancy the secondary pop-up window you can display the installation complete page straight away (adding a failure message at the same time say).

Hope that helps.
0 Kudos
rguggisberg
Level 13

I agree with what Hysteresis said. More details needed.

In your case, since it seems like you have multiple cases where you want to throw an error, I would set two properties in your various InstallScript locations.
FatalError = 1 whenever you encounter error
ErrorMessage = "Some error message appropriate to that error"

Then display a Secondary window if FatalError NEQ 0 and have it display ErrorMessage.
0 Kudos