I want to read the excel file from the particular folder.
In that folder only one excel file will be there but name of that file will get changed.
so everytime when bot runs he only pick the excel file from that folder
I am using excel application scope but in the scope we have to mention file name too so this is not working for me
supriya117
(Supriya Allada)
2
Hi @avinash.wankhede
Try this:
arr_excelFiles = Directory.GetFiles("C:\YourFolderPath", "*.xlsx")
In excel application scope, use arr_excelFiles(0).ToString
or
str_excelFile = Directory.GetFiles("C:\YourFolderPath", "*.xlsx")(0)
In excel application scope, use str_excelFile.ToString
lrtetala
(Lakshman Reddy)
3
Hi @avinash.wankhede
Use For each file in folder activity in that use Excel application scope
Hi @avinash.wankhede ,
You can use that
my code
Sequence.xaml (10.3 KB)
regards,
Hi @avinash.wankhede
Directory.GetFiles("C:\YourFolderPath", "*.xlsx")(0)
It pick the first excel file
or use
For each file in folder

Hope it helps!!
you can mention like this directly in the for each
so it will take only excel files from the folder
@avinash.wankhede
system
(system)
Closed
7
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.