LZlz
February 27, 2020, 7:05pm
1
Hi, Team!
I have a .txt file and I want to keep the first 10 characters from each line.
Can you help me please?
3,0 770331208 500 Pc 418,60 1.883,70
Union flat seat Index 32,20
331 11/2. G Multi 13,00
Discount -10,00%
4,0 770245235 100 Pc 642,20 577,98
Hexagon nipple, reducing Index 49,40
245 21/2.2. G Multi 13,00
Discount -10,00%
Thanks,
1 Like
bcorrea
(Bruno Correa)
February 27, 2020, 7:09pm
2
You can use Read Text File activity and after that you will use:
MyLines = myText.Split(Environment.NewLine, StringSplitOptions.RemoveEmptyEntries)
In a for Each you can use:
myTenChars = item.SubString(0, 10)
3 Likes
There you go. You do have to account for cases where the number of characters in the line is less than 10.
Processusvierge.zip (838,1 Ko)
2 Likes
LZlz
February 27, 2020, 8:43pm
4
Thank you so much for your contribute!
LZlz
February 27, 2020, 8:45pm
5
Thank you so much for your contribute! It helps me gather information. Iām a beginner
1 Like
system
(system)
Closed
March 1, 2020, 8:45pm
6
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.