Announcement

Collapse
No announcement yet.

Batch Script to find and replace a line

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Batch Script to find and replace a line

    Hi All

    can anyone help me out to create a batch script to find and replace a line of a text file.

    For Example

    A text file named test.txt file contains a line::

    This is a test msg

    I just want to replace the whole line with a new text.

    Thank you in advance for any help.

  • #2
    Re: Batch Script to find and replace a line

    My friend Mr provides a few ways:
    https://www.google.co.uk/search?q=cm...HsurhQfimICoBQ

    The first couple of hits offer two different ways of achieving the same result, using different scripting languages
    Tom Jones
    MCT, MCSE (2000:Security & 2003), MCSA:Security & Messaging, MCDBA, MCDST, MCITP(EA, EMA, SA, EDA, ES, CS), MCTS, MCP, Sec+
    PhD, MSc, FIAP, MIITT
    IT Trainer / Consultant
    Ossian Ltd
    Scotland

    ** Remember to give credit where credit is due and leave reputation points where appropriate **

    Comment

    Working...
    X