Download zipped file from web, unzip and rename it after

Hi, I am trying to download zipped files from a website and then unzip and rename it into a specific folder. For the renaming part, I will need to rename it according to a data that scrapped earlier (e.g. rename the file to same as “Ticket Number” since the file is download from this Ticket Number). Is there any possible way to do this?

Thanks,
Sam

Hi,

You can download the file and extract it.
Then use move file activity with the desired name (Ticket Number) and save the file as you need

Well here are the steps I can come up with for the process:

  1. For the list of ticket numbers that you have - run a for each loop.
  2. For every download use unzip file activity (I have seen a component on GO for the same)
  3. While using the copy file or move file activity give the desired ticket number extracted from the loop item
  4. Repeat

hi @Raghavendraprasad

I can’t find any unzip file activity in my UiPath Studio

@sam.lee There is a custom activity created by @balupad14 so you can use this activity have a look here

1 Like

Alright @indra, will give it a try

I tried to use the zip/unzip activity, when I run it and it got faulted. I already insert the zip file path and the unzip file path. Is there any other setting I need to do?

I think it will have some ‘readme’ document follow them step by step I didnt use this exact activity but some other approach I had used maybe scripting.

VB.NET code snippet might be more reliable?

Hi @sam.lee ,
Can you attach the xmal to verify it . It is working well.

Check this link also,

https://forum.uipath.com/t/uipath-go-zip-and-unzip/133375/3?u=balupad14

Regards
Balamurugan.S

2 Likes

Hi @balupad14, I already download the SharpCompress from Manage Packages and I use the Unzip activity then key in the zip file path and the destination path. Once I run it, it still faulted. Please advise.

1 Like

Hi @sam.lee,
Can you send me the zip file via message to investigate.If possible…

Regards
Balamurugan.S

1 Like

Sorry @balupad14, due to contains confidential data, I can’t share the zip file with you. But the error msg shows could not load SharpCompress which I already installed.

@sam.lee,
Send me a sample zip file . I want to see the format how the file it has.

Regards
Balamurugan.S

It’s ok already @balupad14. I have found another solution for it and it’s working. Thanks you so much by the way !!

1 Like

Hi, Can share with me how you managed to rename the unzipped items? Because I am facing the same issue - I could not rename right after the unzipping process, it usually provides me a generic name from using unzip activity

Regards,
Victor

Hi @Victor_Victory,

I downloaded a package called ZipAndUnzipFile.Activities by Priya and use the Unzip activities then just enter your source file path and the destination file path. It’s very simple to use.


2 Likes

thank you!

1 Like

HI @sam.lee,

I have tested the unzip . Normally when you install any new package . The studio has to be closed and restarted it. It has some feature that it is in the below.

Password feature and Code Page (UniCode file.)

Thank you
Balamurugan.S

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.