Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
Make your voice heard! Participate in the 2020 Wisdom of Crowds® Survey. BEGIN SURVEY
Highlighted
munna1317
Contributor II

Unzip Files in a Folder to Destination folder

Hi all ,

i have 10 Zip files in path "C:\Users\AllamHarish\Desktop\ZIPPPP\*.zip"

Here i need to Unzip Files and paste in path "C:\Users\AllamHarish\Desktop\ZIPPPP"

Please help me out with Qlikview

Thanks in advance ,

Harish

1 Solution

Accepted Solutions
Highlighted
munna1317
Contributor II

Re: Unzip Files in a Folder to Destination folder

Solved problem We should have Unzip .exe file then

execute cmd.exe /C unzip -o Source\*.zip -d Destination ;

thanks for All

View solution in original post

5 Replies
Highlighted
vardhancse
Valued Contributor III

Re: Unzip Files in a Folder to Destination folder

Highlighted
munna1317
Contributor II

Re: Unzip Files in a Folder to Destination folder

hi Sasi ,

Thanks for fast replay ,

I have checked this code , but it is for Single ZIP file how to get 10 Zip files on a Click

Thanks in Advance ,

Harish

Highlighted
rahulpawarb
Valued Contributor III

Re: Unzip Files in a Folder to Destination folder

Hello Harish,

Hope that you are doing good!

You can refer below given sample PowerShell script (I am not good at writing PowerShell scripts; compiled it using multiple website):

$fso = new-object -com scripting.filesystemobject

$folder = $fso.getfolder("C:\Users\AllamHarish\Desktop\ZIPPPP\")

foreach ($f in $folder.files) {

  set shellApp = CreateObject("shell.application") 

  set zip = shellApp.NameSpace("c:\users\petter\downloads\testzip\" + $f.name)

  set dest = shellApp.NameSpace("c:\users\petter\downloads\testzip\") 

  dest.Copyhere zip.items() , 20

}

Regards!

Rahul

Highlighted
munna1317
Contributor II

Re: Unzip Files in a Folder to Destination folder

Hi rahul ,

Thanks for Replay , i also dont know how to Execute Code for Power Shell .

Can you please guide me how to Run this code .

like for example for CMD promt

We will write Execute Cmd.exe follwed by Scripting .

For Powershell How to Execute please help me out of this , it is Priority Task please .

Thanks in Advance ,

Harish

Highlighted
munna1317
Contributor II

Re: Unzip Files in a Folder to Destination folder

Solved problem We should have Unzip .exe file then

execute cmd.exe /C unzip -o Source\*.zip -d Destination ;

thanks for All

View solution in original post