I have one shared location so I want to move the input files to shared location.
In Shared location i have to check if month floders available or not for example 1 January, 2 February like this.
If I will run the bot in February month I need to check if 2 February floder is available or not if not I need to create the folder and also inside Feb floder I have create Excess floder and inside the excess floder need to Backup floder and finally I have to move the input files in to backup floder.
Note: if I will run in Oct month BOt need to create the 10 October floder .
before moving folder to destination
assign current month to varible
eg - current_month =DateTime.ParseExact(“01/01/2023”, “dd/MM/yyyy”, Nothing).ToString(“dd MMMM”)
first check inside destination folder that condition where the current month folder is present or not
folder exist activity
path+current_month
if the folder present then move files to that folder
path+currentMonth
All the variables are of DataType System.String. Make sure to change the path in sharedLocation variable. So your shared location will be ending like this "kepptherequiredpath\2024 Monthly Billing"
→ After the Multiple Assign I have used Folder Exists and If. If the folder is already present, it won’t create a new folder. Same in the case of Excess and Backup folder.
According to above flow if you run on January 01 January folder will be created inside that Excess Folder will be create and Inside Excess Folder Backup Folder will be created. Same in the case, If you run in February 02 February Folder will be created and inside that Excess Folder will be create and Inside Excess Folder Backup Folder will be created.
All the variables are of DataType System.String. Make sure to change the path in sharedLocation variable.
→ After the Multiple Assign I have used Folder Exists and If. If the folder is already present, it won’t create a new folder. Same in the case of Excess and Backup folder.
Workflow:
All the variables are of DataType System.String. Make sure to change the path in sharedLocation variable.
→ Use Folder Exists activity and give the below condition and store the output and it’s datatype is Boolean.