The following applicaitons should be closed before continuin - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

romanf
Posts: 4
Joined: Mon Jun 13, 2011 10:04 pm

The following applicaitons should be closed before continuin

Hello,

The environment is Windows 7.
I have created a custom action that closed my installed application. I would like this custom action to be the first thing that runs during the uninstall process.
I've placed this custom action under the "Uninstall". When I uninstall (from the add/remove programs) the application a window pops up with the message: "The following applicaitons should be closed before continuing" and an empty box is displayed. if I choose "do not close applications (a Reboot may be required) only after I press OK on that window my custom action that closes my application runs.
Is there any way to run my custom action before this window appears - to prevent it from appearing?

Thank you,

Roman
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: The following applicaitons should be closed before conti

Hi Roman and welcome to the Advanced Installer Forums,

You can try to schedule your custom action after the Begin standard action in the InstallUISequence and share it( drag and drop holding Shift key ) after the Begin standard action in the InstallExecuteSequence. This way your application should also close when running the uninstall silently.

You custom action should also be set with the following execution condition:

Code: Select all

REMOVE="ALL"
All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
romanf
Posts: 4
Joined: Mon Jun 13, 2011 10:04 pm

Re: The following applicaitons should be closed before conti

Thank you Mihai for your answer.

It seems that running custom action after the Begin standard action is too early - as I get initialization errors.
I believe that the right location to run my custom action that closes my application before uninstall actually starts its action is after CostFinilize.
The thing is that my application takes 3-5 seconds to close and meanwhile the sequence continues and gets to InstallValidate where the BAD "File in use" dialog pops up.
Is there any way to halt execution until my application exists?
The execution properties I use for my custom action is: Synchronous execution, ignore return code.

Regards,

Roman
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: The following applicaitons should be closed before conti

Hi Roman,

Windows Installer continues the execution as soon as the custom action finishes. So you need to make your custom action wait for your application to close. This is usually done through custom code.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”