Is it possible to do a Search/Replace from command line ?

Is it possible to do a Search/Replace from command line ?

6

    Jul 27, 2005#1

    I am new to using command line with UltraEdit.

    What I want to do is run UltraEdit from a command line, pass it a filename and have it search the file for a character and replace that character.

    Any ideas on how to do this ?

    6,681583
    Grand MasterGrand Master
    6,681583

      Re: Is it possible to do a Search/Replace from command line

      Jul 28, 2005#2

      With a macro. Record the search and replace as macro, save the macro to a macro file and run UltraEdit with the command line option to load and execute the macro in the macro file on your file(s), which is(are) also specified on the command line.
      Best regards from an UC/UE/UES for Windows user from Austria

      6

        Re: Is it possible to do a Search/Replace from command line

        Jul 28, 2005#3

        I think I can do the record of the macro, any example on what the command line would look like to run this ?

        Thanks

          Re: Is it possible to do a Search/Replace from command line

          Jul 28, 2005#4

          I think I got it to run, it went by so quick. When I pass it a filename (using /m,e,1="C:\testfile.txt"), will runing the macro on this file save the changes on this file ?

          What I want to do is to run the macro on "testfile.txt" and save the changes made to this file (via search/replace) as a new filename, thanks.

          6,681583
          Grand MasterGrand Master
          6,681583

            Re: Is it possible to do a Search/Replace from command line

            Jul 28, 2005#5

            Add to the macro as last line the command

            SaveAs "New file name.txt"

            You can also add the path, if you want.
            Best regards from an UC/UE/UES for Windows user from Austria

            6

              Re: Is it possible to do a Search/Replace from command line

              Jul 29, 2005#6

              Thanks for your help, I got it to work !