Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I have a text file, it is pretty big (1000 lines approx) and it is formatted like this
words more words even more words 1312331
Every line has a scentence then random numbers at the end. I was wondering if there was a ways, since all the numbers start with 1 and are 7 characters if the was a way to do a variable in replacement. Like replace 1****** with nothing. Any help would be appreciated.
Edit: I cannot delete all numbers because there are numbers in some spots, but none begin with 1 or are 7 characters long.

For starters, are you really hoping to do this in DOS?
Does the alledged a scentence [sic] end with a period?
It may help to post a few lines.
=====================================
If at first you don't succeed, you're about average.M2

No, it does not have a period. Some do but not all.
All the lines are formatted the same
its like this: *'s are numbers******* a scentence is here 1******
I will use any way possible to do this. I just need a simple way to delete any word starting with the number 1 that has 6 other numbers.
Edit:
I have an idea, but i need to know how to just delete a single word, in a batch file. I could do something like this:set number=999999
:start
set /a number=%number%+1
if %number%=="2000000" goto EOF
command to delete word %number%
goto start
:EOFThis would take a while but at least it would be automated. I just need to know the command to delete a single word, if there is one.

Any one have a solution, currently i use change.com, i heard there was a v9.11 that let it use files larger than 32kb. Could you post that?

![]() |
![]() |
![]() |
| Login or Register to Reply | |
| Login | Register |
| Ads by Google |