Please I have this folder structure
GNCR (Main folder) that contains subfolders : (1) Application - Contains Application (2)Menu Folder - Contains the Menu and (3) Data folder which Contains Sub folders which are MainData and ListingData. I then wrote the follow codes in my pff file to run backup anytime the pff file is written but i get path error.
The copy is done on the internal memory of the tablets with <invalid path> error. Kindly assist me as always.
Code: Select all
function gncr()
string pffFilename1 = pathname(Application) + "../Application/gncr.pff";
setfile(pffFile1,pffFilename1,create);
...............................................................
string GCABackup = pathname(CSEntryExternal) + maketext("Backup%d",timestamp());
dircreate(GNCRBackup);
if SU = 1 then
if filecopy(pathname(Application) + "../Data/MainData/GNCRDATA.csdb",GCABackup) = default then
errmsg("Insert an SD card");
elseif filecopy(pathname(Application) + "../Data/ListingData/LIST.csdb",GCABackup) = default then
errmsg("Insert an SD card");
endif;