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

Re: [Clip] Re: Find - Replace

Expand Messages
  • Jeff
    This one takes a text selection (highlighted) and creates a NEW HTL coded page containing no Header or foot. -- ^!KEYBOARD CTRL+C ^!KEYBOARD CTRL+N ^&
    Message 1 of 5 , Jan 1, 2004
      This one takes a text selection (highlighted) and creates a NEW HTL
      coded page containing no Header or foot.
      --

      ^!KEYBOARD CTRL+C
      ^!KEYBOARD CTRL+N
      ^&
      ^!Replace "^P" >> "</p>^P<p>" SAW
      ^!Jump DOC_END
      ^!InsertHtml </p>
      ^!Jump DOC_START
      ^!InsertHtml <p>


      ~~~
      Jeff Scism, IBSSG
      Scismgenie@...

      http://blacksheep.rootsweb.com/
      http://homepages.rootsweb.com/~scismfam/
      http://www.rootsweb.com/~inmontgo/
      http://www.rootsweb.com/~nvchurch/

      A computer without COBOL and FORTRAN is like a piece of chocolate cake
      without ketchup or mustard. (John Krueger)

      Now there is something about 80 columns and 12 zones....OH YES, and the
      notched corner in the upper right... Then there was Burroughs...
    • Lee Underwood
      John, ... This clip adds a at the end of every line. I only need it in the blank lines. Also, it adds the which I do not use. That is the problem with
      Message 2 of 5 , Jan 1, 2004
        John,

        At 1/1/04 03:32 PM, John Zeman wrote:
        >Assuming you are working with some form of HTML, have you tried this?
        >
        >^!Replace "^P" >> "</p>^P<p>" SAW
        >
        >Then just add the following to finish it up.
        >
        >^!Jump DOC_END
        >^!InsertHtml </p>
        >^!Jump DOC_START
        >^!InsertHtml <p>


        This clip adds a <p> at the end of every line. I only need it in the blank
        lines. Also, it adds the </p> which I do not use. That is the problem with
        the method below. I am just trying to write a clip to do it the way I want
        it with out the other coding, which I would then have to erase.

        Lee

        >Now having said that, it sounds to me like you do not need a clip to
        >do what you want. I'll often have a need to convert an entire
        >document of plain text into HTML (excluding the HTML header and
        >footer). To do that, I simply go to the NoteTab OPTIONS/INTERNET tab
        >and set the html headers and footers to nothing if necessary (Delete
        >everything in each box).. Then I'll just run the NoteTab tool
        >of "Document to HTML" on the active text document and the text is
        >converted to HTML just as you are wanting to do it. Bear in mind the
        >original text document needs to be in the correct layout before
        >conversion. That is, the paragraphs should be double-spaced and
        >wherever you desire <br> elements to be inserted, just have single
        >line breaks. For example:
        >
        >
        >THIS WOULD BE A PARAGRAPH OF TEXT WHEN CONVERTED TO HTML.
        >
        >THIS WOULD BE ONE LINE IN ANOTHER PARAGRAPH FOLLOWED BY A LINE BREAK.
        >THIS WOULD BE ANOTHER LINE IN THE SAME PARAGRAPH FOLLOWED BY A LINE
        >BREAK.
        >THIS WOULD BE A THIRD LINE IN THE SAME PARAGRAPH FOLLOWED BY A
        >CLOSING PARAGRAPH TAG.
        >
        >
        >Which after the document to html conversion would be:
        >
        >
        ><p>THIS WOULD BE A PARAGRAPH OF TEXT WHEN CONVERTED TO HTML.</p>
        >
        ><p>THIS WOULD BE ONE LINE IN ANOTHER PARAGRAPH FOLLOWED BY A LINE
        >BREAK.<br>
        >THIS WOULD BE ANOTHER LINE IN THE SAME PARAGRAPH FOLLOWED BY A LINE
        >BREAK.<br>
        >THIS WOULD BE A THIRD LINE IN THE SAME PARAGRAPH FOLLOWED BY A
        >CLOSING PARAGRAPH TAG.</p>
        >
        >
        >John
      • John Zeman
        Ok Lee, then you might try using something this as a template for a clip. ^!Replace ^P^P | ATIWS ^!Replace ^P ATIWS ^!Replace |
        Message 3 of 5 , Jan 1, 2004
          Ok Lee, then you might try using something this as a template for a
          clip.

          ^!Replace "^P^P" >> "|" ATIWS
          ^!Replace "^P" >> "<br>" ATIWS
          ^!Replace "|" >> "^P^P<p>" ATIWS

          The first line in the clip temporarily replaces all double spaced
          (^P^P) lines with a character not found in your text document (I used
          the pipe (|) character).

          The second line in the clip replaces the remaining ^P with <br>

          And the third line changes the temporary | character used in the
          first step into ^P^P<p>

          You may have a trailing <br> at the very end to delete if you had an
          line break there, and you won't have an opening <p> tag if the very
          first paragraph is at the top of the page, but otherwise it should do
          what you want unless I'm not understanding you correctly.

          John



          --- In ntb-clips@yahoogroups.com, Lee Underwood <lee@t...> wrote:

          > This clip adds a <p> at the end of every line. I only need it in
          the blank
          > lines. Also, it adds the </p> which I do not use. That is the
          problem with
          > the method below. I am just trying to write a clip to do it the way
          I want
          > it with out the other coding, which I would then have to erase.
          >
          > Lee
          >
        Your message has been successfully submitted and would be delivered to recipients shortly.