Community
    • Login

    problems with apostrophies

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    3 Posts 2 Posters 1.1k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • James LongJ Offline
      James Long
      last edited by

      Hello!
      I’m trying to perform a find and replace to swap about 40,000 instances of “Organization’s Name” (minus quotation marks) with a generic moniker in several thousand HTMs. For the life of me, Notepad++ will not find any instances of Organization’s Name. When I remove the apostrophe, the find feature works flawlessly.

      When I search ONLY for “Organization” within Notepad++, I see a lot of the instances I’m looking for, and the possessive version of Organization shows up as:
      Organization�s (this is a direct copy and paste from Notepad++, however in the notepad++ UI, the wonky ASCII character is an empty box)

      How can I fix this? I’ve opened these HTMs in Notepad, and the plaintext is exactly as you’d expect it: Organization’s Name

      Any help would be greatly appreciated.

      Alan KilbornA 1 Reply Last reply Reply Quote 0
      • Alan KilbornA Offline
        Alan Kilborn @James Long
        last edited by Alan Kilborn

        @James-Long said in problems with apostrophies:

        the wonky ASCII character

        The problem is that the apostrophe is not ASCII; in fact ASCII is a dying notion. The “in thing” is now Unicode, and that’s what you’ve got, and probably UTF-8.

        Without diving in too far and looking up the peculiarities of that specific “character”, a replacement like this might work:

        Find what box: Organization(.)s Name
        Replace with box: Generic Moniker\1s Name
        Match case checkbox: ticked
        Wrap around checkbox: ticked
        Search mode radiobutton: Regular expression <---- this is the KEY part
        Press the Replace All button

        Of course, that assumes you want to keep the “wonky” character. If you don’t, what I’ve provided for the Find what box will probably at least get you finding what you need; replace with whatever you want.

        Looking up the exact character would be more precise. Maybe try selecting your search term and then pressing Ctrl+f – this should copy what is selected directly into the Find what box.

        1 Reply Last reply Reply Quote 5
        • James LongJ Offline
          James Long
          last edited by

          Alan, you are my hero. Thank you!!

          1 Reply Last reply Reply Quote 3

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors