New to Batch scripting

Home Forums Scripting DOS Command Shell New to Batch scripting

This topic contains 4 replies, has 4 voices, and was last updated by Avatar sumedh_vsk 5 years, 5 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • Avatar
    wonderbread
    Member
    #164014

    I’m new to batch scripting and I’m trying to write a command that will remove the first four lines of a file.
    The end goal is to have the program find the file, get rid of everything in the file except a list of numbers, and add save the new file. Any help would be greatly appreciated!

    #385413

    Re: New to Batch scripting

    What kind of file?

    Avatar
    sumedh_vsk
    Member
    #390181

    Re: New to Batch scripting

    it’s a .txt file

    Avatar
    James Haynes
    Member
    #252019

    Re: New to Batch scripting

    i think it would be easier to script the extraction of what you want from the txt and then creating a new txt from the extract, then delete the old file after successful copy of said data… but im not a script master.

    #385414

    Re: New to Batch scripting

    I thought that might be the case. However, I don’t know of any commands that would do what you want. A batch file is basically a series of DOS commands. I know of no such command that could identify and target specific lines in a .txt file. I’ll let one of the other take over. :)

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.