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

Re: [Clip] Search & Replace ... but no replace

Expand Messages
  • hsavage
    ... Robert, Don t know of any readily available character charts but, I would recommend loading each of the Word files into Word and save as text files, that
    Message 1 of 24 , Oct 8, 2006
    • 0 Attachment
      Robert Kelsey wrote:
      > Hello All,
      >
      > I have a regular chore that entails replacing characters generated by
      > other software, probably Word, where they do not display correctly
      > online, on web pages, in particular using Mozilla Firefox browser.
      >
      > When I try to do a search and replace via a clip everything works
      > fine EXCEPT for a few characters.
      >
      > Anyone have any ideas?
      > --Robert Kelsey

      Robert,

      Don't know of any readily available character charts but, I would
      recommend loading each of the Word files into Word and save as text
      files, that will probably get rid of most of your problems. It will, at
      least, get rid of all the Word formatting stuff and make your job a
      little easier.

      ºvº
      2006.10.08
      "Did the aliens forget to remove your anal probe?"
      hrs ø hsavage@...
    • Axel Berger
      ... I could guess. But it would be better if could could save a short example, ZIP it (to make sure it survives transport strictly as-is) and attach it here.
      Message 2 of 24 , Oct 8, 2006
      • 0 Attachment
        Robert Kelsey wrote:
        > Anyone have any ideas?

        I could guess. But it would be better if could could save a short
        example, ZIP it (to make sure it survives transport strictly as-is) and
        attach it here.

        Axel
      • Axel Berger
        ... It might. But I have had similar problems and if all those files already exist, loading them siongly into some nasty package is a pain - much better,
        Message 3 of 24 , Oct 8, 2006
        • 0 Attachment
          hsavage wrote:
          > that will probably get rid of most of your problems.

          It might. But I have had similar problems and if all those files already
          exist, loading them siongly into some nasty package is a pain - much
          better, faster and easier to do it in NoteTab. I have a TXT2HTML clip
          that deals with all the ideosyncracies in my files, which come from
          "save as text" out of an old and obsolete Atari wordprocessor in just
          one go.

          Axel
        • hsavage
          ... Sorry guys, If you zip a sample you ll have to send it directly to Axel, no attachments are allowed on these lists. ºvº 2006.10.08 Did the aliens forget
          Message 4 of 24 , Oct 8, 2006
          • 0 Attachment
            Axel Berger wrote:
            > Robert Kelsey wrote:
            >> Anyone have any ideas?
            >
            > I could guess. But it would be better if could could save a short
            > example, ZIP it (to make sure it survives transport strictly as-is) and
            > attach it here.
            >
            > Axel

            Sorry guys,

            If you zip a sample you'll have to send it directly to Axel, no
            attachments are allowed on these lists.

            ºvº
            2006.10.08
            "Did the aliens forget to remove your anal probe?"
            hrs ø hsavage@...
          • Don - HtmlFixIt.com
            I did this a while back for a librarian. The problem is that they are curly quotes in the orig and you want to replace with straight quotes.
            Message 5 of 24 , Oct 8, 2006
            • 0 Attachment
              I did this a while back for a librarian. The problem is that they are
              curly quotes in the orig and you want to replace with straight quotes.
            • adrien
              ... I think you can turn this off in Word itself. After done this, just search and replace in Word self. -- adrien
              Message 6 of 24 , Oct 9, 2006
              • 0 Attachment
                Op zo, 08-10-2006 te 22:26 -0400, schreef Don - HtmlFixIt.com:
                > I did this a while back for a librarian. The problem is that they are
                > curly quotes in the orig and you want to replace with straight quotes.

                I think you can turn this off in Word itself. After done this, just
                search and replace in Word self.
                --
                adrien
              • Pat(kitPatH)
                ... Robert, if those nonstandard ascii characters show up in a text document, then look under nt s MODIFY menu. The last option should/might be Convert to
                Message 7 of 24 , Oct 9, 2006
                • 0 Attachment
                  At 10/9/2006, you wrote:
                  >1c. Search & Replace ... but no replace
                  > Posted by: "Robert Kelsey" rdkelsey1113@... rdkelsey1113
                  > Date: Sun Oct 8, 2006 4:48 pm (PDT)
                  >
                  >I have a regular chore that entails replacing characters generated by
                  >other software, probably Word, where they do not display correctly
                  >online, on web pages, in particular using Mozilla Firefox browser.
                  >
                  >When I try to do a search and replace via a clip everything works
                  >fine EXCEPT for a few characters.
                  >
                  >The apostrophe which I try to replace with the character next to the
                  >"enter" key
                  >The double quotes which I try to replace with the shift of the key
                  >next to the "enter" key.
                  >
                  >When I made the clip I did a copy/paste from the original document.
                  >When I run the clip these items do not get replaced. I figure there
                  >is some other actual character, or series of keystrokes, that represents them?
                  >
                  >Anyone have any ideas?



                  Robert, if those nonstandard ascii characters show up in a "text" document, then
                  look under nt's MODIFY menu. The last option should/might be "Convert to ascii"

                  those nonstds show up mostly using the ansi. I do something similar in a brute force
                  clip; adding "odd characters" as i find them.

                  The trick is to never save as ascii before running the clip.

                  Here's an example of what some of what I put into a H=replace nonascii chars - clip

                  ;Accents mac and pc
                  ^!Replace "ù" >> " -- " TWSA
                  ^!Replace "—" >> " -- " TWSA
                  ^!Replace "à" >> "a" TWSA
                  ^!Replace "à" >> "a" CWSA
                  ^!Replace "ç" >> "c" TWSA
                  ^!Replace "á" >> "a" TWSA
                  ^!Replace "á" >> "a" CWSA
                  ^!Replace "â" >> "a" TWSA
                  ^!Replace "Ô" >> "a" TWSA
                  ^!Replace "é" >> "e" TWSA
                  ^!Replace "Ú" >> "U" TWSA
                  ^!Replace "ú" >> "u" TWSA
                  ^!Replace "è" >> "e" TWSA
                  ^!Replace "ê" >> "e" TWSA
                  ^!Replace "ë" >> "e" TWSA
                  ^!Replace "þ" >> "E" TWSA
                  ^!Replace "É" >> "E" TWSA
                  ^!Replace "È" >> "E" TWSA
                  ^!Replace "Ê" >> "E" TWSA
                  ^!Replace "î" >> "i" TWSA
                  ^!Replace "í" >> "i" TWSA
                  ^!Replace "÷" >> "o" TWSA
                  ^!Replace "Ó" >> "o" TWSA
                  ^!Replace "ó" >> "o" TWSA
                  ^!Replace "ñ" >> "n" TWSA
                  ^!Replace "Ñ" >> "N" TWSA
                  ^!Replace "û" >> "u" TWSA
                  ^!Replace "ù" >> "u" TWSA
                  ^!Replace "ü" >> "u" TWSA
                  ^!Replace "Æ" >> "'" TSA
                  ^!Replace "æ" >> "'" TSA

                  ;html
                  ^!Replace "=46" >> "F" TWSA
                  ^!Replace "=E9" >> "e" TWSA
                  ^!Replace "=EA" >> "e" TWSA
                  ^!Replace "=AE" >> "®" TWSA
                  ^!Replace "?iso-8859-1?Q?" >> "" TWSA
                  ^!Replace "=B0" >> "" TWSA
                  ^!Replace "=20^P" >> ^P TWSA

                  ;Other TCIBGWHRSA
                  ^!Replace "•" >> "*" CWSA
                  ^!Replace "•" >> "*" CWSA
                  ^!Replace "ò" >> "*" CWSA
                  ^!Replace " and " >> " and " CWSA
                  ^!Replace ’ >> ' TWSA
                  ^!Replace ‘ >> ' TWSA
                  ^!Replace ` >> ' TWSA
                  ^!Replace “ >> " TWSA
                  ^!Replace ” >> " TWSA
                • Pat
                  ... A second window!!! Thank you once again for finding the easiest solution. Much appreciated! pat ********** H= Display Announcement 2nd Window ; source
                  Message 8 of 24 , Oct 9, 2006
                  • 0 Attachment
                    --- In ntb-clips@yahoogroups.com, hsavage <hsavage@...> wrote:
                    >

                    A second window!!!
                    Thank you once again for finding the easiest solution.
                    Much appreciated! pat

                    **********
                    H="Display Announcement 2nd Window"
                    ; source unknown modified by "hsavage" 2006-10-08
                    ^!SAVE
                    ^!Open "C:\Documents and Settings\.....etc...\announcement.txt"
                    ^!Menu Document/Second Window
                    **********

                    Cursor is in the template window where I can copy a stock-phrase if
                    need be..
                  • Pat
                    If it s just the curly quotes, again I use the brute force. and if they are being replacing, I convert doc to ansi and try again. =pat **** H= Replace
                    Message 9 of 24 , Oct 9, 2006
                    • 0 Attachment
                      If it's just the curly quotes, again I use the brute force. and if
                      they are being replacing, I convert doc to ansi and try again. =pat

                      ****
                      H="Replace MS-quotes"
                      ^!Replace " >> " TWAS
                      ^!Replace " >> " TWAS
                      ^!Replace ">> " TWAS
                      ^!Replace ">> " TWAS
                      ^!Replace '>> ' TWAS
                      ****
                    • Don Daugherty
                      ... You might be able to find out what the actual character is via a variation on the following sample ^!Continue —=^$CharToDec( — )$ The odd character
                      Message 10 of 24 , Oct 9, 2006
                      • 0 Attachment
                        Robert Kelsey wrote:
                        > When I made the clip I did a copy/paste from the original document.
                        > When I run the clip these items do not get replaced. I figure there
                        > is some other actual character, or series of keystrokes, that represents them?
                        >
                        > Anyone have any ideas?
                        >
                        You might be able to find out what the actual character is via a
                        variation on the following sample
                        ^!Continue —=^$CharToDec("—")$
                        The odd character appeared as a solid black square in NTP, as a very
                        long dash in my email program, and turns out to have a code of 151, as
                        revealed by the above clip line. Perhaps you can copy each character
                        (one at a time) into the above clip and execute it to found out it's
                        code number. If so, you could do a conversion similar to this example
                        ^!Replace "^$CharToDec("—")$" >> "--"
                      • Robert Kelsey
                        Hi All, I zipped a file off to you Axel, thanks for the offer. It has some of the problem characters. I guess I brought up quite an issue with this situation.
                        Message 11 of 24 , Oct 10, 2006
                        • 0 Attachment
                          Hi All,

                          I zipped a file off to you Axel, thanks for the offer. It has some of
                          the problem characters.

                          I guess I brought up quite an issue with this situation. It appears
                          there is more to it than originally thought.

                          I appreciate the accented character changes as well.

                          As much as it probably portrays us Americans as uncaring about
                          another languages spellings or use of characters, for my own search
                          engine listing needs, I really need to omit the accented characters.
                          I don't think many Americans will search utilizing accented
                          characters, and I don't think Google handles that, as a for instance
                          saute with the accented e.

                          Anyone have insight on how Google USA handles accented words and if
                          it would return a file with saute or saute with the accented e?

                          --Robert Kelsey

                          At 08:19 PM10/8/2006, you wrote:

                          >Robert Kelsey wrote:
                          > > Anyone have any ideas?
                          >
                          >I could guess. But it would be better if could could save a short
                          >example, ZIP it (to make sure it survives transport strictly as-is) and
                          >attach it here.
                          >
                          >Axel
                          >


                          [Non-text portions of this message have been removed]
                        • Hugo
                          ... Hi Robert, The results differ: http://www.google.com/search?q=saut%C3%A9 http://www.google.com/search?q=saute Hugo
                          Message 12 of 24 , Oct 10, 2006
                          • 0 Attachment
                            > Anyone have insight on how Google USA handles accented words and if
                            > it would return a file with saute or saute with the accented e?
                            >
                            > --Robert Kelsey
                            >
                            >
                            Hi Robert,

                            The results differ:

                            http://www.google.com/search?q=saut%C3%A9
                            http://www.google.com/search?q=saute

                            Hugo
                          • Axel Berger
                            ... I must admit that up to now I had not seen what the fuss was about. It seems this is an undocumented quirk if not a bug in NoteTab. First off for all
                            Message 13 of 24 , Oct 10, 2006
                            • 0 Attachment
                              Robert Kelsey wrote:
                              > It appears there is more to it than originally thought.

                              I must admit that up to now I had not seen what the fuss was about. It
                              seems this is an undocumented quirk if not a bug in NoteTab. First off
                              for all those, who don't get it messed up on the way, this is the
                              example I was sent:

                              You don’t have to be a veterinarian to be able to be part of “Connecting
                              Animals to People…”
                              Anyway, I am sure you get the picture. Basically, he wanted business
                              cards and his little slogan is “Jack-Of-All-Trades”.
                              - When you're at the hospital, there is one way to find the north tunnel
                              without heading to the south wing first
                              - One way that people have been able to find the Veterinary Hospice is
                              ‘Yellow Page'.

                              Just using <Ctrl<<C> <Ctrl><V> and the menu function <Ctrl><R> worked
                              perfectly as expected. So I tried the obvious (i.e. copied the offending
                              characters into the clip):

                              ^!Replace "“" >> """ WA
                              ^!Replace "”" >> """ WA
                              ^!Replace "…" >> "..." WA
                              ^!Replace "‘" >> "'" WA
                              ^!Replace "´" >> "'" WA

                              No luck. Next I opened the file in a hex viewer and tried this:

                              ^!Replace "\x93" >> """ WRA
                              ^!Replace "\x94" >> """ WRA
                              ^!Replace "\x85" >> "..." WRA
                              ^!Replace "\x92" >> "'" WA
                              ^!Replace "\x91" >> "'" WA

                              It worked for the double quotes and the triple dot, but not the single
                              quotes. No idea why. Then finally I did it this way:

                              ^!Replace "^P" >> "<BR>" WA
                              ^!MENU Modify/Characters to HTML/Extended Characters
                              ^!Replace "‘" >> "'" WA
                              ^!Replace "’" >> "'" WA
                              ^!Replace "“" >> """ WA
                              ^!Replace "”" >> """ WA
                              ^!Replace "…" >> "..." WA
                              ^!MENU Modify/Strip HTML Tags/Preserve URLs

                              This works, but depending on what else there is in the text, especially
                              tags, can have all kinds of side effects.

                              Axel
                            • Axel Berger
                              ... Quite. I just wanted to say this was not a good suggestion for the general case. ... They are quite clever in this way. Whenever I enter an accented
                              Message 14 of 24 , Oct 10, 2006
                              • 0 Attachment
                                Robert Kelsey wrote:
                                > for my own search engine listing needs, I really need to omit
                                > the accented characters.

                                Quite. I just wanted to say this was not a good suggestion for the
                                general case.

                                > Anyone have insight on how Google USA handles accented words

                                They are quite clever in this way. Whenever I enter an accented (German)
                                character in a word they will find only that, iirc. But with French and
                                other accents not directly accessible to my keyboard I don't bother and
                                enter just the base letter. They then find all the accented versions as
                                well. So well done Google, that's exactly how this customer likes it.

                                Axel
                              • Don Daugherty
                                ... Excuse the Dumb Attack in the last line above. It could properly be any one of the following: ^!Replace ^$DecToChar(151)$ whatever I want
                                Message 15 of 24 , Oct 10, 2006
                                • 0 Attachment
                                  Don Daugherty wrote:
                                  > You might be able to find out what the actual character is via a
                                  > variation on the following sample
                                  > ^!Continue —=^$CharToDec("—")$
                                  > The odd character appeared as a solid black square in NTP, as a very
                                  > long dash in my email program, and turns out to have a code of 151, as
                                  > revealed by the above clip line. Perhaps you can copy each character
                                  > (one at a time) into the above clip and execute it to found out it's
                                  > code number. If so, you could do a conversion similar to this example
                                  > ^!Replace "^$CharToDec("—")$" >> "--"
                                  >
                                  Excuse the "Dumb Attack" in the last line above. It could properly be
                                  any one of the following:
                                  ^!Replace "^$DecToChar(151)$" >> "whatever I want"
                                  ^!Replace "—" >> "whatever I want"
                                  ^!Replace "^$DecToChar(^$CharToDec("—")$)$" >> "whatever I want"
                                • Axel Berger
                                  ... Well the first of those doesn t work as I said already and the second doesn t either. The problem is that when you paste certain characters into the clip
                                  Message 16 of 24 , Oct 10, 2006
                                  • 0 Attachment
                                    Don Daugherty wrote:
                                    > ^!Replace "—" >> "whatever I want"
                                    > ^!Replace "^$DecToChar(^$CharToDec("—")$)$" >> "whatever I want"

                                    Well the first of those doesn't work as I said already and the second
                                    doesn't either. The problem is that when you paste certain characters
                                    into the clip they are not found. I really think this is a bug.

                                    Axel
                                  • Don Daugherty
                                    ... That s really strange. I guess the multiple ways of coding characters represents a challenge that hasn t been fully conquered in NTP, et. al. I assume you
                                    Message 17 of 24 , Oct 10, 2006
                                    • 0 Attachment
                                      Axel Berger wrote:
                                      > Don Daugherty wrote:
                                      >
                                      >> ^!Replace "—" >> "whatever I want"
                                      >> ^!Replace "^$DecToChar(^$CharToDec("—")$)$" >> "whatever I want"
                                      >>
                                      >
                                      > Well the first of those doesn't work as I said already and the second
                                      > doesn't either. The problem is that when you paste certain characters
                                      > into the clip they are not found. I really think this is a bug.
                                      >
                                      > Axel
                                      >
                                      That's really strange. I guess the multiple ways of coding characters
                                      represents a challenge that hasn't been fully conquered in NTP, et. al.
                                      I assume you are copying the character after it has been read into
                                      NoteTab (rather in the original application) so that whatever internal
                                      processing NoteTab has already done is reflected in the copy.

                                      Does pressing Shift-F12 make any difference in the appearance in the
                                      neighborhood of the character in question (indicating there is some
                                      hidden character that is part of the its total code?)

                                      The scheme I outlined does work for me in my application where I take a
                                      pdf file, save it as text in Adobe Reader, and than process that in
                                      NoteTab, but I certainly can believe that your case can be significantly
                                      different. If I get any other ideas I'll pass them along. Good luck.

                                      P.S.
                                      I just tried something that I think was suggested by someone else. I
                                      loaded the text version of the pdf file I mentioned above, and manually
                                      performed the equivalently ^!Menu "Modify/Characters To HTML/Extended
                                      Characters". The resulting code for my "Square box", which appeared as a
                                      very long dash in the email, was — and the code for a non-standard
                                      quote or apostrophe was ’ I don't know whether this could be of
                                      use in your problem, but if it does anything unique then perhaps you
                                      could do a series of find and replace operations on the resulting new codes.
                                    • Don Daugherty
                                      ... One more observation: When I clicked on Modify in the menu I noticed an item Convert to Ascii Text . I clicked that and my special characters changed to
                                      Message 18 of 24 , Oct 10, 2006
                                      • 0 Attachment
                                        Axel Berger wrote:
                                        > The problem is that when you paste certain characters
                                        > into the clip they are not found. I really think this is a bug.
                                        >
                                        > Axel
                                        >
                                        One more observation:
                                        When I clicked on Modify in the menu I noticed an item "Convert to Ascii
                                        Text". I clicked that and my special characters changed to new ones.
                                        Also I discovered that the menu item had changed to "Convert to Ansi
                                        Text". Clicking that seemed to change it back to what I started with.
                                      • Alec Burgess
                                        Axel, Robert (hsavage): Or upload the file to the files area of this group so other interested parties can have a look as well Regards ... Alec --
                                        Message 19 of 24 , Oct 10, 2006
                                        • 0 Attachment
                                          Axel, Robert (hsavage):
                                          Or upload the file to the files area of this group so other interested
                                          parties can have a look as well
                                          Regards ... Alec -- buralex-gmail
                                          --


                                          hsavage said the following on 2006-10-08 20:29:
                                          > Axel Berger wrote:
                                          > > Robert Kelsey wrote:
                                          > >> Anyone have any ideas?
                                          > >
                                          > > I could guess. But it would be better if could could save a short
                                          > > example, ZIP it (to make sure it survives transport strictly as-is) and
                                          > > attach it here.
                                          > >
                                          > > Axel
                                          >
                                          > Sorry guys,
                                          >
                                          > If you zip a sample you'll have to send it directly to Axel, no
                                          > attachments are allowed on these lists.
                                          >
                                          > ºvº
                                          > 2006.10.08
                                          > "Did the aliens forget to remove your anal probe?"
                                          > hrs ø hsavage@...
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                          > Fookes Software: http://www.fookes.us, http://www.fookes.com
                                          > Fookes Software Mailing Lists: http://www.fookes.us/maillist.htm
                                          >
                                          > Yahoo! Groups Links
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                          >
                                        • Axel Berger
                                          ... None at all (I have that turned on permanently anyway). As I said, I have looked at the file in a hex viewer and, more importantly, pasting into the
                                          Message 20 of 24 , Oct 10, 2006
                                          • 0 Attachment
                                            Don Daugherty wrote:
                                            > Does pressing Shift-F12 make any difference in the appearance in the
                                            > neighborhood of the character in question (indicating there is some
                                            > hidden character that is part of the its total code?)

                                            None at all (I have that turned on permanently anyway). As I said, I
                                            have looked at the file in a hex viewer and, more importantly, pasting
                                            into the replace menu dialogue works. It is a quirk in clips and only
                                            there.

                                            > but I certainly can believe that your case can be significantly
                                            > different.

                                            Everything works as expected with most special characters, it's just
                                            some that are bothersome.

                                            If I get any other ideas I'll pass them along. Good luck.

                                            > I don't know whether this could be of use in your problem

                                            Erm, you did see my message from "Date: Tue, 10 Oct 2006 13:40:49
                                            +0200"?
                                            I had already solved the problem and using exactly that way. The problem
                                            here is that after dealing with the problem cases you need to undo the
                                            "Characters to HTML" by a "Strip HTML Tags" and depending on what else
                                            there is in the file this may produce unwanted effects. It will destroy
                                            linefeeds, I had to treat them specially anyway.

                                            Axel
                                          Your message has been successfully submitted and would be delivered to recipients shortly.