Hi,
I am facing issues while running the excel script. I have added the vb code for renaming and copying file but its doesn’t work in RPA excel scripts. It working in other process.
I tried to test it with excel macro then it works fine issue with the RPA script for excel recorder.
So to avoid script i used file operation activity but got some error" illegal path characters." Attaching the screen shot about same.
My source path will be like -“C:\Users” & Environ$(“username”) & “\Downloads\ALCON*.xlsx”
I am assuming you have only or more excel file to copy and rename based on pattern which starts with ALCON.
I am not sure why VB script is giving error to you.
There are several other ways to make it work -
→ Using File Search & File Operation Activity (Includes Excel Loop)
→ Using PowershellActivity (Simple & Starightforward)
Solution for File Search & File Operation Activity
First, you’ll have to use File Search to search for file with pattern.
For File Search, your source path will be formed by assigning an argument with - “C:\Users”+Environment.Username+"\Downloads"