How to rename the downloaded pdf file

Hi All,

I have to rename a downloaded pdf file with specific name “UHC_File.pdf” which is present in Download folder.

The downloaded pdf file will be with the name “pd-pd-20220201-20220211-767000414070-H-SCHEDULE-ALL”

Please do needful

@ppr
@Yoichi
@ushu
@Nithinkrishna
@Gokul001

Hija,

you can just use a move file activity. oldname in From and new name in To

Hey @HeartCatcher

Rename File activity will do the job.

Thanks
#nK

Ok, but I need to save in pdf format even after renaming

1 Like

Okay, Then just use Move File activity with destination mentioned with new updated filename and extension which should do the job.

Hello @HeartCatcher

You can use Move file or copy file activity. In the destiantion path give the newpath/newname.pdf Then it will save with the new name in the destination folder.

newpath is the full path of the destination folder
newname is the new name of the pdf file


is that the format correct??

yes, now it will save in c:\users\NaveenkuS7\Pictures\screenshots as. “Health_Plan_Description_Abcd_wxyz.pdf”

Instead of hardcoding the entire path in the activity, better to save the destination path in an asset or in the config file. In future if you want to change, you dont need to modify in the script and you can change direclty in the config or asset.

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