i have some files in folder…
- Swiggy MPR Monthly----->09 - Swiggy December-2021
- Swiggy Cancel File—> 09-Swiggy Cancellation Working December-2021
- Swiggy reconcilation File----> 09 - Swiggy Reconciliation Differences December, 2021
i want to get Swiggy Mpr Monthly File . Can any one help how to get this file ?
Getting the filePaths of the files within a directory
within an assign activity
Leftside: your Variable of Datatype: String Array
please watch the below video fr your reference
Use Assign activity
LHS → Variable of Datatype → String Array
RHS → Directory.GetFiles(“FolderPath”,“Swiggy MPR Monthly*”)
i want Swiggy Mpr file only .to send this file to out Argument. this file name will be use in other workflow
Use @Gokul001 approach. You will be good.
Try this expression above
hi , i used directory and for each loop . getting each file name .
swiggy MPR monthly file format like-- 09 - Swiggy December-2021.
it might be change for every month --For exp if January come…
10 - Swiggy January -2022.
i want to get this file name dynamically .
i used this condtion but i am not getting exact file name. getting other file name
Can you share the exact input file name here
Swiggy MPR Monthly File-----------------> 09 - Swiggy December-2021
if file name changes dynamically with respect to month
then in If condition you can use like this
Try this expression
Directory.GetFiles("Your folderpath","Swiggy MPR Monthly File-----------------"+DateTime.Now.ToString("dd")+" - Swiggy "+DateTime.Now.ToString("MMMM-yyyy"))
Alternative based on the workflow
How to add -2 months this syntax ?
Try this expression
we can setup a regex pattern like:
And if a more detail date check is needed we can rely to the groups:
for further evaluations
As an alternate:
If pattern is reliable then we can generate the string for the month of interest and use it for the file retrieval
Thank you for given solution . its working fine…
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.