kwn4ever2
Flexera beginner

Installshield unable to backup a folder  before installing new files

I am not able to have my install script to copy all the files from an installed folder (C:\ProgramData\CompanyName\ProductName\config) to a backup folder (C:\ProgramData\CompanyName\ProductName\config_20210930[10:12:01]) before installing the new files to it.  Instead it copied the newly installed files to the backup folder.

Example:

nResult = XCopyFile ( C:\ProgramData\CompanyName\ProductName\config\myfile.txt, C:\ProgramData\CompanyName\ProductName\config_20210930[10:12:01], COMP_NORMAL);

Labels (1)
0 Kudos
1 Reply
varul
Revenera
Revenera

What is your project type?

Are you doing upgrade like when version1 is installed before installing verison2 you are creating backup of version1 is my understanding correct?

If you are using the script as a customaction then you need to sequence it at app search of installexec sequence or any anything before uinstalling older version or updating older version.

If you are using install script function , try on firstuibefore

 

https://docs.revenera.com/installshield21helplib/Subsystems/installshield21langref/helplibrary/Langr...

 

https://docs.revenera.com/installshield22helplib/Subsystems/installshield22langref/helplibrary/Langr...

0 Kudos