RajeshT
(Rajesh)
October 10, 2019, 3:15am
1
Hi Team,
How to compare text file with the excel file.
Excel file Values:BG000011,BG000022,BG000033…
If excel file values matches with any line of text file,copy the total line of data in to another text file.
Appreciate your immediate help.
Regards,
Rajesh
ImPratham45
(Prathamesh Patil)
October 10, 2019, 4:25am
2
Firstly Take those excel values in a variable
then for text file split it by new line
then using If condition in For each of splited data u can compare…
1 Like
sarathi125
(Parthasarathi)
October 10, 2019, 5:00am
3
Hi,
Check this xaml, I have placed the excel and textfile on my desktop then tried with the xaml.
I have created my own excel file since I do not have idea on your file format. ReadExcelAndCheck.xaml (7.6 KB)
Book1.xlsx (9.5 KB)
1 Like
RajeshT
(Rajesh)
October 10, 2019, 6:27am
4
Hi @sarathi125 ,
Thank you for the response,
I have changed the files path based on your xaml and tried with your xaml but its copying the whole data from text file.
I need to copy the excel data matching lines to be copied in to new test file.
Also in desktop 3 files are copying.May i know why?
New,New1 and New2 files >
Attached the exact files for reference.AgentData_Disbursement_UnsuccessfulAgents.xlsx (8.5 KB) TextFile.zip (769 Bytes)
Regards,
Rajesh
sarathi125
(Parthasarathi)
October 10, 2019, 6:33am
5
For each string from the excel we are creating a new files, thats why you are getting three files on your desktop.
RajeshT
(Rajesh)
October 10, 2019, 6:35am
6
Thank you for the response sarathi. @sarathi125
My requirement is to check in text file whether the excel values is matching in any of the text file,if yes then copy the total line.
Regards,
Rajesh
RajeshT
(Rajesh)
October 10, 2019, 6:38am
7
Expected output i have attached.TextFile Output.zip (599 Bytes).
I want to add data in one file same as attached.
sarathi125
(Parthasarathi)
October 10, 2019, 6:48am
8
ReadExcelAndCheck.xaml (10.3 KB)
Check the updated workflow and let me know in case of any query
2 Likes
RajeshT
(Rajesh)
October 10, 2019, 7:00am
9
This is Perfect!!
Thanks a lot @sarathi125 .
Appreciate your time!!
RajeshT
(Rajesh)
October 10, 2019, 10:23am
10
Hi @sarathi125 ,
Need small change,can we keep header and footer as same using same code.
Regards,
Rajesh
sarathi125
(Parthasarathi)
October 10, 2019, 10:28am
11
Do you mean this “UnsuccessfulAgents” as the header and which one is the footer?
RajeshT
(Rajesh)
October 10, 2019, 11:03am
12
Summary file header and footer needs to add.
sarathi125
(Parthasarathi)
October 10, 2019, 11:12am
13
ReadExcelAndCheck.xaml (11.2 KB)
Check this workflow, I assume always the footer will be your last line in the summary text file.
RajeshT
(Rajesh)
October 10, 2019, 4:54pm
14
Hi @sarathi125 ,
Header is fine but footer is missing when i use huge file to compare.
Could you help why footer is missing.
Sorry for late reply,as i am out of office.
Regards,
Rajesh
RajeshT
(Rajesh)
October 11, 2019, 1:34am
15
Hi @sarathi125 ,
When i use summary file with less records footer is adding but when i use summary file with huge(More than 50000 records) footer is missing.
How to overcome this?
Thank you,
Rajesh
sarathi125
(Parthasarathi)
October 11, 2019, 5:15am
16
Hi,
Check with the footer and header activity like this,
1 Like
RajeshT
(Rajesh)
October 11, 2019, 9:17am
17
Thank you @sarathi125 ,
This is working perfect !!.
Regards,
Rajesh
system
(system)
Closed
October 14, 2019, 9:29am
18
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.