Xbase++
Xbase++
Reassemble a Previously Split File
Demonstrates how to reassemble a previously split file.Chilkat Xbase++ Downloads
LOCAL nSuccess
LOCAL oFac
LOCAL cReassembledFilename
LOCAL cPartPrefix
LOCAL cPartExtension
LOCAL cSrcDirPath
nSuccess := 0
oFac := CreateObject("Chilkat.FileAccess")
// Any type of file may be reassembled. It doesn't matter if it's
// a binary file or a text file.
cReassembledFilename := "hamlet2.xml"
cPartPrefix := "hamlet"
cPartExtension := "spl"
cSrcDirPath := "."
// Reassembles the original file from hamlet1.spl, hamlet2.spl, ...
nSuccess := oFac:ReassembleFile(cSrcDirPath, cPartPrefix, cPartExtension, cReassembledFilename)
IF (nSuccess == 1)
? "Success."
ELSE
? oFac:LastErrorText
ENDIF
oFac:destroy()