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

Installing external file...


4 replies to this topic

kadey

kadey
  • Members
  • 6 posts

Posted 15 February 2006 - 15:25

I need to install an external file (one not included in the .msi package). I thought I could use a Custom Action to launch an executable (xcopy.exe) to accomplish this (similiar to launching notepad.exe to view a readme file), but I'm getting an error 1722.

Any help would be appreciated.

Thanks.

Ken....


kadey

kadey
  • Members
  • 6 posts

Posted 16 February 2006 - 15:41

Hmm....is this one of those questions that's been asked/answered a zillion times (but I can't find a previous reference to)?

Ken....


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 18 February 2006 - 11:09

Be patient, it may take more than one day to get an answer here. wink.gif

Windows Installer by default checks the exit code of the exe launched as custom action. Any return value other than 0 will be interpreted as fatal error and will cause the setup to about with error 1722. If your copy operation actually works properly then you should set the custom action to ignore the return value.

But did you look at the MoveFile table? This might be a better solution (it has a flag to copy instead of move).

kadey

kadey
  • Members
  • 6 posts

Posted 21 February 2006 - 20:20

I got it to work by using a Deferred CA with a condition ("Not Installed").

I did look at the MoveFile (and other) tables, but it seems to me that references to files in these tables cannot be resolved externally at execution time. Ie, references are to Component Features included in the installation project, and resolved at installation build time (not execute time).

Ken....


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 22 February 2006 - 10:28

The Component_ column in the MoveFile table only is used as a condition. The actual file name and location is defined by the other columns in that table.