I currently have a text file which looks like this
2010.26 (0.0306746) @ 59,19
I want to remove all 22 characters up till the "59"
NOTE: REMOVE, not replace with (null)
NOTE2: The 59 CANNOT be taken as a number to consider in the script... it is not fixed. The only thing that is fixed is the 20 characters at the start till we reach the 59.
furthermore I want to replace the "," with a "+" sign.
start beginning from the end of the file and delete every thing after the fifth character (59)
> maybe this can be achieved by reading the 5 last characters of the line and write it to the same text file ?
Ok, the replacing part will work like this:
set /p text= <textfile.txt
set str=%text%
echo.%str%
set str=%str:text-to-replace=replacing-text%
ECHO %str% > textfile.txt
---------- Post updated at 11:40 AM ---------- Previous update was at 10:11 AM ----------
Is there a way to read the last - lets say 7 characters- from a line into a variable ?