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

DoInstall returns -2147024864


1 reply to this topic

Matthias1967

Matthias1967
  • Full Members
  • 92 posts

Posted 14 November 2008 - 15:37

Hi,

In an IS9 InstallScript Project, I call another IS9 InstallScript setup with DoInstall. Under certain circumstances, the return value of DoInstall is -2147024864 ("The process cannot access the file because it is being used by another process").

I tried to solve the issue by commenting out code, checked return values of all file access functions, but I could not find the reason for this error code yet.

So I am wondering about how the return code of DoInstall is set. Does it have anything to do with errors occurring within the child setup? If so, can the error bookkeeping somehow be accessed from script? Would it be helpful to query the Err object, or is this a different thing?

Thanks for any help.

Matthias1967

Matthias1967
  • Full Members
  • 92 posts

Posted 17 November 2008 - 11:32

In my case, I could finally solve the problem. Since this issue has been raised several times in install communities, I would llike to explain it here.

Monitoring file system activity by Filemon (or a similar tool) proved very helpful.
So I found out that an application which my child install had started with LaunchAppAndWait started another application which persisted and used a dll in the SUPPORTDIR of the child setup.

When setup.exe tried to clean up the child setup, the dll could be deleted (I do not know why), but the folder containing the dll (i.e. the SUPPORTDIR of the child setup) was still locked by the persistent application, resulting in a sharing violation when trying to open it for deletion.

Generally, I think that an error code returned by DoInstall only refers to errors that occur in the DoInstall function itself (preparing and cleaning up the child install), not to errors that occur in the child setup script.

Edited by Matthias1967, 25 November 2008 - 11:54.