Loading ...
Sorry, an error occurred while loading the content.
 

Re: [Clip] Replacing Text

Expand Messages
  • Alec Burgess
    Harvey: I m pretty sure Jody has done something very like this in his clips library but since you were considering a Visual Basic program, I thought I d
    Message 1 of 4 , Jun 27, 2002
      Harvey:

      I'm pretty sure Jody has done something very like this in
      his clips library but since you were considering a Visual
      Basic program, I thought I'd suggest a "purpose built"
      answer that's worked well for me and can do exactly what
      you seem to be asking for. It doesn't explicitly support
      comments but you can stick a search replace pair in that
      you KNOW will fail and get exactly the same effect.
      (You'll see what I mean if you look at the program;-)
      >>BK ReplaceEm
      Welcome to the wonderful world of BK ReplaceEm, your
      premiere-quality, freeware string-replacing utility for
      Windows 95/98/NT. At its core, BK ReplaceEm is
      essentially a text search-and-replace program. However,
      unlike the search-replace functionality of a standard
      text editor, BK ReplaceEm is designed to operate on
      multiple files at once. And you need not only perform one
      search-replace operation per file -- you can setup a list
      of operations to perform. If different groups of files
      need to have different operations performed on them, this
      is no problem either. You can also specify a backup file
      for each file processed just incase the replace operation
      didn't do exactly what you wanted. <<
      http://www.orbit.org/replace/

      Regards ... Alec
      cc: Off-topic

      ---- Original Message ----
      From: "Harvey Segal" <hsegal@...>
      To: <ntb-clips@yahoogroups.com>
      Sent: 25 June, 2002 06:46
      Subject: [Clip] Replacing Text

      > I asked someone if they could write
      > a program eg in Visual Basic to do
      > the following but I just wonder
      > if there is a clip which may do part
      > of this.
      >
      > -------------------------------------
      > Program runs through a folder
      > of files and replaces strings of text
      > The strings and their replacements
      > would be held on a separate
      > 'control' file.
      >
      > The format of the control file would
      > be say
      >
      > original string1
      > replacement string 1
      > original string2
      > replacement string 2
      > etc
      >
      > And a useful extra would be that a
      > line beginning with * is a comment.
      >
      > ---------------------------------------
      >
      >
      > Harvey
      >
      >
      >
      > ------------------------ Yahoo! Groups
      Sponsor -----------
      > ----------~--> Free $5 Love Reading
      > Risk Free!
      >
      http://us.click.yahoo.com/3PCXaC/PfREAA/Ey.GAA/dkFolB/TM
      > -------------------------------------------------------
      ---
      > -----------~->
      >
      >
      >
      > Your use of Yahoo! Groups is subject to
      > http://docs.yahoo.com/info/terms/
    • Harvey Segal
      ...
      Message 2 of 4 , Jun 27, 2002
        On 27 Jun 2002 at 13:20, Alec Burgess wrote:

        > I'd suggest a "purpose built"
        > answer that's worked well for me and can do exactly what
        > you seem to be asking for. It doesn't explicitly support
        > comments but you can stick a search replace pair in that
        > you KNOW will fail and get exactly the same effect.
        <
        > http://www.orbit.org/replace/

        Alec,

        Brilliant, this is EXACTLY what I want,

        Many thanks,

        Harvey
      • Christine F. Muehling
        Speaking of replacing text, I didn t need the extra results file Harvey needed, and someone recommended Text Exchange to me. I thought I d died and gone to
        Message 3 of 4 , Jun 27, 2002
          Speaking of replacing text,
          I didn't need the extra results file Harvey needed, and someone recommended
          Text Exchange to me.
          I thought I'd died and gone to heaven. What a simple, clean solution!

          I was so happy I sat down and did a ton of converting to CSS on a gudzillion
          files. I was practically cheering.

          I regret I can't remember whom to thank here, but if you're reading this,
          you made someone's live not only happier, but a ton easier!

          Christine
        • Jody
          Hi Michael, (This was sent to my notetab-owner yahoo address for some reason - the mail return bounces. Anyway, you won t see the original.) Take out the
          Message 4 of 4 , Jul 2, 2002
            Hi Michael,

            (This was sent to my notetab-owner yahoo address for some reason
            - the mail return bounces. Anyway, you won't see the original.)

            Take out the space behind: "Set %bcol%=^$GetCol$ " That should
            take care off it, but I only looked at the Clip in mail.

            Check the option to trim blanks or something like that under the
            File or Document tab to take care of things like that after Save.
            It removes any trailing blanks.

            >The following clip, which is supposed to search for a first string,
            >then a second one, and select the text between (with the intent of
            >deleting it later), doesn't work:
            >
            >^Jump 1
            >^!Find "<!--mikeworks header-->"
            >^!Jump SELECT_START
            >^!Set %bcol%=^$GetCol$
            >^!Set %brow%=^$GetRow$
            >^!Find "<!--end mikeworks header-->"
            >^!Jump SELECT_END
            >^!SelectTo ^%brow%:^%bcol%
            >
            >Everything up to the ^!SelectTo ^%brow%:^%bcol% line works, but no
            >selection is occurring. If I replace the ^%brow% and ^%bcol% with
            >integers, it does correctly select the text and if I display those
            >variables after the last line, they display the correct values.
            >Any ideas?
            >
            >thanks,
            >Michael Brock

            Happy Clip'n!
            Jody

            http://www.notetab.net

            Subscribe, UnSubscribe, Options
            mailto:Ntb-Clips-Subscribe@yahoogroups.com
            mailto:Ntb-Clips-UnSubscribe@yahoogroups.com
            http://groups.yahoo.com/group/ntb-clips
          Your message has been successfully submitted and would be delivered to recipients shortly.