Dear SebSpiers,
there may be several causes at the root of your issue.
A- First of all and if your target is a x64 system, please consider that by default any setup package runs as a native 32bit application. Due of this, any call that points to a system directory or to HKLM system registry, it will be redirected by the system to the respective x86 location.
In other words, trying to store something to; "C:\Windows\System32" this will be stored to "C:\Windows\SysWOW64" instead.
At such purpose you may force the installer to instruct a native x64 process using the "Set x64 - Native 64 bit Windows, ..." statement.
B- also consider that because you are trying to store a file under a system restricted area ("C:\Windows\System32"), the process requires full administrative privileges to be completed successfully.
C- even for "cmd.exe" you should consider the behavior that I described at point #A. If your target is a x64 system, there are two distinct versions of the "cmd.exe" (the cmd-exe embeds the DOS Copy command). The native x64 version is available under "system32" while the respective x86 Platform version is stored under "SysWOW64". Consequently if your setup runs as a native 32bit application, the one effectively used will be the respective x86 "cmd.exe" under "SysWOW64".
That said, you may try the following;
Code: Select all
Set x64 - Native 64 bit Windows, AMD64 and EM64T Architectures - installation mode
Set Variable SYS_DIR to
Get Folder Location System->System Directory into SYS_DIR
Run Program "$SYS_DIR$\cmd.exe" /c copy "C:\Temp\applicationHost.config" "$SYS_DIR$\inetsrv\config\applicationHost.config" /y (WAIT)
Set Win32 - Native 32 bit Windows and Windows 32 on Windows 64 (WOW64) - installation mode
the same as above in "InstallAware Clipboard Data";
Code: Select all
~InstallAware Clipboard Data~
~Comment~
~{FA49E179-57A1-4B32-B446-4F578588D9EB}~
~~
~Set 64 Bit Mode~
~{8EE9F2EA-8C47-46DC-88CF-132D134353CF}~
~TRUE~
~FALSE~
~FALSE~
~Run Program~
~{31580F40-CDEA-4098-A876-1008DB8AA64E}~
~"$SYS_DIR$\cmd.exe"~
~TRUE~
~/c copy "C:\Temp\applicationHost.config" "$SYS_DIR$\inetsrv\config\applicationHost.config" /y~
~TRUE~
~~
~Get Folder Location~
~{60723E82-FC27-4FD7-94E9-A95A38413FFA}~
~SYS_DIR~
~23~
~FALSE~
~Set Variable~
~{31424C06-0E45-4C33-829E-93C552F8A5F8}~
~SYS_DIR$MYAH$MYAH$FALSE~
~~
~Comment~
~{F1142BD4-F34F-43F3-9E59-CD4437521131}~
~~
~Set 64 Bit Mode~
~{08C518DB-FFC8-42CE-9E53-617714928A3D}~
~FALSE~
~FALSE~
~TRUE~
Alternatively and in place of the "CMD.EXE", you may use the IA "Copy/Move Local Files" command. Note this is a Windows Installer Command (PURPLE COMMANDS) and in order to execute it immediately, it's necessary to switch ON the InstallAware Native Engine.
Code: Select all
Set x64 - Native 64 bit Windows, AMD64 and EM64T Architectures - installation mode
Set Variable NATIVE_ENGINE to TRUE
Set Variable SYS_DIR to
Get Folder Location System->System Directory into SYS_DIR
Copy Local Files "C:\Temp" \applicationHost.config to "$SYS_DIR$\inetsrv\config"\applicationHost.config
Set Variable NATIVE_ENGINE to FALSE
Set Win32 - Native 32 bit Windows and Windows 32 on Windows 64 (WOW64) - installation mode
the same as above in "InstallAware Clipboard Data";
Code: Select all
~InstallAware Clipboard Data~
~Set 64 Bit Mode~
~{8D5C21D0-3396-4D81-BE3E-75EB4627CCB3}~
~TRUE~
~FALSE~
~FALSE~
~Set Variable~
~{D9A2E9F2-7648-4F2E-AD54-3F406C4751FF}~
~NATIVE_ENGINE$MYAH$MYAH$FALSE~
~FALSE~
~Copy/Move Local Files~
~{7DB220A1-D8C3-4749-8ED4-A7CBE1E081EF}~
~"C:\Temp" ~
~applicationHost.config~
~"$SYS_DIR$\inetsrv\config"~
~applicationHost.config~
~TRUE~
~FALSE|FALSE~
~Get Folder Location~
~{0F9A8F89-2AB4-41CB-B97F-2E720D9ACB8A}~
~SYS_DIR~
~23~
~FALSE~
~Set Variable~
~{ED66B34F-E5B0-4751-B53C-36ACB6B0F8CC}~
~SYS_DIR$MYAH$MYAH$FALSE~
~~
~Comment~
~{1FFD47FD-23DF-4FDA-A30D-8C30AD3E9D8F}~
~~
~Set Variable~
~{F8BCCBA9-40E3-45E7-9AC9-5CD32BAEFCC5}~
~NATIVE_ENGINE$MYAH$MYAH$FALSE~
~TRUE~
~Set 64 Bit Mode~
~{D0535D7F-C13B-4351-BE12-D5B8FF009AF3}~
~FALSE~
~FALSE~
~TRUE~
Finally, some useful links;
https://www.installaware.com/forums/viewtopic.php?f=2&t=4603https://www.installaware.com/forums/viewtopic.php?f=2&t=4338Hope this helps you.
Regards