Visual FoxPro
Visual FoxPro
Decode Base64 to Zip File
See more Base64 Examples
Shows how to decode a baes64 string that is the encoded representation of the bytes that make up a .zip archive. Decodes the base64 and writes the .zip file.Chilkat Visual FoxPro Downloads
LOCAL lnSuccess
LOCAL lcB64
LOCAL loZipData
lnSuccess = 0
lcB64 = "UEsDBBQA ... AAALgQAAAAA"
loZipData = CreateObject('Chilkat.BinData')
lnSuccess = loZipData.AppendEncoded(lcB64,"base64")
lnSuccess = loZipData.WriteFile("qa_output/out.zip")
IF (lnSuccess <> 1) THEN
? "failed to write Zip file."
RELEASE loZipData
CANCEL
ENDIF
RELEASE loZipData