Page 1 of 1

wrong files locked after windows service installation

Posted: Tue Sep 01, 2015 5:17 pm
by rodm
I am using InstallAware X2 Studio build 12.1.14. During the install I copy a list of files from an installation folder to the target folder. After the files are copied I create a service using one of the files in the target folder (myService.exe). I use the “Run .NET Installer” command. It creates the service and it all works. But, while the service is running I cannot delete the file “myService.exe” in the installation folder. It says the file “myService.exe” is in use by the service I had just created. I checked which file the service was using and it is “myService.exe” in the target folder, as it should be. It uses nothing from the installation folder. If I stop the service then I can delete “myService.exe” from the installation folder. Our old Wise scripts that did the same job did not do this behaviour. It seems that the InstallAware scripts are the cause of this behaviour. Is there any way to prevent this?

Re: wrong files locked after windows service installation

Posted: Wed Sep 02, 2015 12:55 pm
by FrancescoT
Dear Rodm,

I suppose instead that the cause of your issue is not the IA script behavior.

Honestly its not clear to me what do you mean exactly with "installation path", are you adding such service to supportdir location?

In other words, it seems to me that you are installing that "myService.exe" in the TARGETDIR (via Install Files) as any other file eventually installed by the package. If true, why did you want to remove such file from there?

Probably I missing your steps, but it seems to me that there is something wrong with the approach you used.

Regards