Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Please help! Stop existing service or disable "file in use"


3 replies to this topic

maxk

maxk
  • Full Members
  • 38 posts

Posted 15 November 2013 - 06:02

Hello,

 

I want my installer (using Installshield 2012) to stop the existing service before copying the files which are being used by the service. So I created a custom action to stop the service.

 

working directory                        systemfolder
file name&command line           "[SystemFolder]net.exe" stop myservice
Return processing                      synchronous (ignore exit code)
in-script execution                      Deferred Execution in System Context

 

When the installer is at "validating install" stage I kept getting the "file in use" dialog

with two options. I'm not sure why my custom action didn't run successfully.

If I click "Automatically close and attempt to restart the applications" option,

everything works fine but I don't want users to get this dialog.

 

Anything wrong with my custom action?

Is there anyway to disable (doesn't show) the dialog box and stop the service?

or any other suggestion?

 

Thanks in Advance,

Max

 

 

Attached Images

  • fileinuse.jpg


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 15 November 2013 - 08:35

Your custom action is running too late.



maxk

maxk
  • Full Members
  • 38 posts

Posted 15 November 2013 - 14:57

Hi Stefan,

 

Could you please be more specific?

I tried to put my custom acton several ways in both UI and Exec sequences but still couldn't get the service to stop.

 

Thanks in advance.



Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 18 November 2013 - 19:13

The FilesInUse dialog is displayed by the InstallValidate action. Your custom action would have to be sequenced before InstallValidate.