Can we automate notepad?

I had a requirement for notepad which consists of multiple rows. Starting from second row until last row alternatively need to do backspace. Do we have any solution for this?

Hey! Welcome to community!

Could you please provide some input data so that will get to know…

Is that data in Excel or Text file?

Regards,
NaNi

Hello.

If I understand correctly, you can make a read text file and for each line, you can enter a trimEnd.

Hug

Data is in Text File.

Data is in Text file. Please find the below same data. In each row I need to get T & U in one row. For example 0330116300001T & 0330116300002U are in different rows but these two rows need to be in single line.

0330116300001T 060227130000130030247 2000000001272 1020013015001 25072020000000006179359341001660045003287082400102402022 092074626615000164CFHFKD COMRMKI DE LAIRJHREK LTDA 01300302470000000000000000000000000
0330116300002U 060000000004201900000000000000000000000000000000000000000000000000000000246960000000000246960000000000000000000000000000002005202223052022000000000000000000000000000 00000000000000000000000
0330116300001T 060227130000130030247 2000000001349 1020013058001 26082020000000006179359341001660045003287082400103702022 092074626615000164CFHFKD COMRMKI DE LAIRJHREK LTDA 01300302470000000000000000000000000
0330116300002U 060000000004201900000000000000000000000000000000000000000000000000000007520990000000007520990000000000000000000000000000002005202223052022000000000000000000000000000 00000000000000000000000

Hey!

You’re deleting something from the text file right?

What kind of data you’re deleting from the text file?

We can also use find and replace options to replace the text with nothing…

Regards,
NaNi

No here I am not deleting any data. Need to do backspace for each row where T & U need to be in same line for all rows.

Hi!

Try this:

For U data

System.Text.RegularExpressions.regex.Match(OutputVar,"\d.+U").ToString

For T data

System.Text.RegularExpressions.regex.Match(OutputVar,"\d.+T").ToString

Reference:

Regards,
NaNi

Hello @anudeep.bandharam

Are you trying to fetch the string ending with U & T and need to concatenate both?

No need to merge entire rows for below example it need to start from “0330116300001T” and need to end with “46960000000000246960000000000000000000000000000002005202223052022000000000000000000000000000 00000000000000000000000”
Need to merge entire two rows.

0330116300001T 060227130000130030247 2000000001272 1020013015001 25072020000000006179359341001660045003287082400102402022 092074626615000164CFHFKD COMRMKI DE LAIRJHREK LTDA 01300302470000000000000000000000000
0330116300002U 060000000004201900000000000000000000000000000000000000000000000000000000246960000000000246960000000000000000000000000000002005202223052022000000000000000000000000000 00000000000000000000000
0330116300001T 060227130000130030247 2000000001349 1020013058001 26082020000000006179359341001660045003287082400103702022 092074626615000164CFHFKD COMRMKI DE LAIRJHREK LTDA 01300302470000000000000000000000000
0330116300002U 060000000004201900000000000000000000000000000000000000000000000000000007520990000000007520990000000000000000000000000000002005202223052022000000000000000000000000000 00000000000000000000000