VBScript
VBScript
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 VBScript Downloads
Dim fso, outFile
Set fso = CreateObject("Scripting.FileSystemObject")
'Create a Unicode (utf-16) output text file.
Set outFile = fso.CreateTextFile("output.txt", True, True)
success = 0
b64 = "UEsDBBQA ... AAALgQAAAAA"
set zipData = CreateObject("Chilkat.BinData")
success = zipData.AppendEncoded(b64,"base64")
success = zipData.WriteFile("qa_output/out.zip")
If (success <> 1) Then
outFile.WriteLine("failed to write Zip file.")
WScript.Quit
End If
outFile.Close