UnZip Folder Windows

Good Day!
Can anyone advise how to unzip the zip file using Xojo on (Windows)?
I check with MBS plugin , but unable to find the example.

Did you check the MBS Compression Plugin?
We have Archive classes.
And the examples like untar could unpack the zip:

One solution is to download 7Z and use their DLL’s. Works fine. No license needed.

1 Like

Good Evening!

I try below [/Compression/Archive/Extract files in Archive] , but i got IOException , error number 104

Works very well.

1 Like

can you help me out ?
I create test.zip file in desktop
inside , have 2 folder and 1 file.

when I Run “[Compression/Archive/Extract files in Archive]” this one I got the IO Error.

it can’t create the file. Check what path file is, maybe a wrong one?
is the output folder created already?

“is the output folder created already?”

No , Need to create output folder manually?

you should get more familiar with file IO handling. Your error (104) is shown due to the fact that the file already exists when you try to create it. Better use this snippet:

var file as FolderItem = SpecialFolder.Temporary.Child("test.tmp")
var b as BinaryStream
var data as string


   if not file.Exists then 
       b = BinaryStream.Create(file) 
       b = BinaryStream.Open(file)
   end if
  while not b.EndOfFile
    data = b.Read(1024*1024, Encodings.UTF8)
end try

it works pretty good as you see here: