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

Re: Adding a character to end of every line?

Expand Messages
  • thefrank
    Here is a simple Clip to add any char or string to the end of a line. Constraints are: 1. Word Wrap should be turned off. 2. Better to Trim Blanks first. 3.
    Message 1 of 8 , Sep 30, 2001
    • 0 Attachment
      Here is a simple Clip to add any char or string to the end of a line.
      Constraints are:

      1. Word Wrap should be turned off.
      2. Better to Trim Blanks first.
      3. Place cursor at 0 position of first line you wish to add to.

      -----

      Add [ string ] to EOL
      ^!SetWizardLabel Add To End of Row
      ^!Set %Insert%=^?[Select text to add to the end of each row]
      ^!Set %Counter%=^?[How many lines?]
      :Loop
      ^!Jump LINE_END
      ^!InsertText ^%Insert%
      ^!Jump +1
      ^!Dec %Counter%
      ^!If ^%Counter% > 0 Loop Else End

      -----

      Here is another I use just as often, with same constraints as above:

      -----

      Insert [ string ] at [ n ] Spaces
      ^!SetWizardLabel Insert At nnn Spaces
      ^!Set %Insert%=^?[Type in or paste text to insert]
      ^!Set %Where%=^?[Number of spaces to begin insert]
      ^!Set %Counter%=^?[How many lines?]
      :Loop
      ^!MoveCursor +^%Where%
      ^!InsertText ^%Insert%
      ^!Jump +1
      ^!Dec %Counter%
      ^!If ^%Counter% > 0 Loop Else End

      -----

      I usually save the doc I am working on before using the clip, and
      test on a few lines to confirm I have correct insert position. Then
      Edit>Reload to revert doc to last saved status. After the clip has
      run you can also Undo one line at a time...

      I have found the above methods easily solve your specific issue but
      also work for any character or whole string as well. If you already
      know what you want to insert and where in the line (position) you
      want it, just insert it; there is no need to search and replace.

      Regards,

      tf

      > someone might already have one that will do this...
      > Regards, Rick
    Your message has been successfully submitted and would be delivered to recipients shortly.