Hello how i can do something like that:
I have this in txt file:
02h00GMT 5146.49 05h00GMT 5146.49 07h00GMT 5182.04 07h10GMT 5183.14 07h20GMT 5179.29 07h30GMT 5182.89 07h40GMT 5189.93 07h50GMT 5190.87 08h00GMT 5194.33 08h10GMT 5198.78 08h20GMT 5202.05 08h30GMT 5196.33 08h40GMT 5200.43 08h50GMT 5196.92 09h00GMT 5199.25 09h10GMT 5197.99 09h20GMT 5201.05 09h30GMT 5198.18
I wanna this:
02h00GMT 5146.49
05h00GMT 5146.49
07h00GMT 5182.04
07h10GMT 5183.14
and so on
Can you help me write code?
Thanks
add enter in txt files
Go to Batch replace tab, check on "Use regular expressions".
In fact "enter" in terms of regular expressions is:
\r\n
Now in order identify one pair we can use the following:
\d+h\d+GMT \d+\.\d{2}
First of all you may try the following:
Put into the grid, search for:
(\d+h\d+GMT \d+\.\d{2})
Replace with:
$1\r\n
Now if you need more precise results:
for example you have 5 pairs in one line and each line ends with enter
(\r\n\)
in this case use the following:
Search for:
(\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2})\r\n
Replace with:
$1\r\n
$2\r\n
$3\r\n
$4\r\n
$5
In fact "enter" in terms of regular expressions is:
\r\n
Now in order identify one pair we can use the following:
\d+h\d+GMT \d+\.\d{2}
First of all you may try the following:
Put into the grid, search for:
(\d+h\d+GMT \d+\.\d{2})
Replace with:
$1\r\n
Now if you need more precise results:
for example you have 5 pairs in one line and each line ends with enter
(\r\n\)
in this case use the following:
Search for:
(\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2}) (\d+h\d+GMT \d+\.\d{2})\r\n
Replace with:
$1\r\n
$2\r\n
$3\r\n
$4\r\n
$5
yea this works but i found in my txt files value like this:
10h10GMT 5200.8 10h20GMT 5205.0 10h30GMT 5203.86 10h40GMT 5203.05 10h50GMT 5208.17 11h00GMT 5208.62 11h10GMT 5210.68 11h20GMT 5210.34 11h30GMT 5208.08 11h40GMT 5206.3 11h50GMT 5203.1 12h00GMT 5200.3 12h10GMT 5205.8 12h20GMT 5205.31
if you see after dot will be sometimes one decimal "d{2}" must be change but for what :/
I dont have another data only these problem it is one digit but sometimes is 2 digit after dot
Can you resolve this problem?
i no have idea how to do that
10h10GMT 5200.8 10h20GMT 5205.0 10h30GMT 5203.86 10h40GMT 5203.05 10h50GMT 5208.17 11h00GMT 5208.62 11h10GMT 5210.68 11h20GMT 5210.34 11h30GMT 5208.08 11h40GMT 5206.3 11h50GMT 5203.1 12h00GMT 5200.3 12h10GMT 5205.8 12h20GMT 5205.31
if you see after dot will be sometimes one decimal "d{2}" must be change but for what :/
I dont have another data only these problem it is one digit but sometimes is 2 digit after dot
Can you resolve this problem?
i no have idea how to do that