Announcement

Collapse
No announcement yet.

Copy File Operation fails

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Copy File Operation fails

    MSI Factory V2.1.1009.0
    Win 10 64 bit

    I have an install project where I want to copy a DLL file from SysWOW64 to System32 after the file installation step completes. However, when I run the install, the file doesn't show up in System32, and I can't figure out why. I think I have the destination folder and the copy operations set up properly, but I can't tell for sure.

    I tried to attach my msifact file, but I got an 'Invalid File' error?? So I uploaded it as a .TXT file.

    TIA,

    Frank



    Attached Files

  • #2
    Hello,

    I removed my previous suggestion from this thread, as sadly it also does not work as expected. What you ask for cannot be done. Here is what happens with my suggestion:

    Code:
    MSI (c) (78:74) [21:14:11:185]: WIN64DUALFOLDERS: 'C:\Windows\SysWOW64\' will substitute 20 characters in 'C:\Windows\system32\' folder path. (mask argument = 0, the folder pair's iSwapAttrib member = 1).
    MSI (c) (78:74) [21:14:11:185]: PROPERTY CHANGE: Modifying System64Folder property. Its current value is 'C:\Windows\system32\'. Its new value: 'C:\Windows\SysWOW64\'.
    MSI (c) (78:74) [21:14:11:185]: Target path resolution complete. Dumping Directory table...
    This excerpt of the installer log shows that any attempt to access a 64-bit folder from a MSI built to target x86 will be changed silently by the WIN64DUALFOLDERS feature in Windows Installer. Windows Installer will not let you access the folder reserved to 64-bit applications.

    The workaround is to perform this - if you really need this - using another tool or command, not controlled by Windows Installer. But you may want to reflect if you really need to deploy both files - your application will only use one, matching the bitness of the application, which cannot be both 32 and 64-bit.

    Ulrich

    Comment


    • #3
      Ulrich,

      Don't you love Microsoft Windows, where you simply can't get from here to there? ;-). What happens if I change the platform from x86 to x64?

      Frank

      Comment


      • #4
        Ulrich,

        I was able to accomplish the file copy using an external .BAT file that gets executed with Admin privileges just after the file install step.

        However, now I have another question. Is there a way for me to execute a separate .BAT file as part of UNinstall processing? I looked at the possible InstallExecuteSequence timing conditions and I see (among others) 'Remove Files', but I don't see anything that would lead me to believe that this is part of the UNinstall operation.

        TIA,

        Frank

        Comment


        • #5
          You can set a condition on the execution of the batch file. To run during install, you can set the condition to NOT Installed, and to run during removal, one option is to set the condition to REMOVE="ALL". You can find more here:

          https://docs.microsoft.com/en-us/win...atement-syntax

          Ulrich
          Last edited by Ulrich; 03-22-2019, 06:36 PM.

          Comment

          Working...
          X