• Post Reply Bookmark Topic Watch Topic
  • New Topic

Move particualr line to particular postion in the text document.  RSS feed

 
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I am trying to do the following after finding this line "Min: " in the text document I want to write it after this line stop "mon-fri" in the new text document or if it possible in the same text document and then delete the empty newline where the Min: line was found. With the current state the line are being changed and not located as in the result simple. How can I fix it?

I appreciate any help.

Simple:
4
stop mon-fri
Chinese
death Radbruch-Platz
operator
Min:30
apologized
cooperate
4
stop mon-fri
government computers
WASHINGTON
suspected
Min:15
Chinese
hackers

Result should looks like this:
4
stop mon-fri
Min:30
dominant 2
death Radbruch-Platz
operator
apologized
cooperate
4
stop mon-fri
Min:15
government computers
WASHINGTON
suspected
Chinese
hackers

Code:

 
Saloon Keeper
Posts: 3330
46
Eclipse IDE Firefox Browser Java MySQL Database VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Where did "dominant 2" come from?
 
Sheriff
Posts: 4289
127
Chrome Eclipse IDE Java Postgres Database VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What's going wrong with the code?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!