View Single Post
  #7  
Old 05-10-2019, 04:51
KaktoR's Avatar
KaktoR KaktoR is offline
Lame User
 
Join Date: Jan 2012
Location: From outer space
Posts: 4,689
Thanks: 1,106
Thanked 7,337 Times in 2,839 Posts
KaktoR is on a distinguished road
Quote:
Originally Posted by ZAZA4EVER View Post
function FileCopy(const '{app}\openingmovie.bk2', '{app}\openingmovie_hi.bk2': String; const FailIfExists: Boolean): Boolean;

How i use it ,, in isdone script or original script i a can not appy it

Code:
FileCopy(ExpandConstant('{app}\openingmovie.bk2'), ExpandConstant('{app}\openingmovie_hi.bk2'), False);
Boolean is always 'True' or 'False'.

You can also use something like this
Code:
[ Code]
var
ResultCode: Integer;

ShellExec('open', 'cmd.exe', '/c copy /Y "' + ExpandConstant('{app}\openingmovie.bk2') + '" "' + ExpandConstant('{app}\openingmovie_hi.bk2') + '"', '', SW_Hide, ewWaitUntilTerminated, ResultCode);
In this example inno setup use cmd.exe from windows os and use it to copy a file with parameters /c /y


You have to use one of the the above codes somewhere after install procedure (at the time when the game is installed, like on finish page).
__________________
Haters gonna hate

Last edited by KaktoR; 05-10-2019 at 04:59.
Reply With Quote