Community
    • Login

    Finding strings that start in a specific column

    Scheduled Pinned Locked Moved General Discussion
    5 Posts 2 Posters 4.4k Views 1 Watching
    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.
    • e5584071E Offline
      e5584071
      last edited by

      Can anyone please advise how to search for character strings that start in a specific column?

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

        @e5584071

        Well you aren’t very specific, but maybe this can get you started:

        Find: (?-s)^.{3}\K.
        Search mode: regular expression

        This will find a single character beginning in column 4 of every line that has 4 or more characters.

        Yep, I realize that there is going to be more to your statement-of-problem after you read this response.

        e5584071E 1 Reply Last reply Reply Quote 3
        • e5584071E Offline
          e5584071 @Alan Kilborn
          last edited by

          @alan-kilborn , can you please explain the syntax of this statement? I don’t see anything that specifies column 4. Thanks very much.

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

            @e5584071 said in Finding strings that start in a specific column:

            I don’t see anything that specifies column 4.

            It’s related to the 3 (one less than 4).
            The syntax is saying skip the first 3 characters on a line and match on something starting in column 4.
            Exact syntax can be looked up in the user manual.

            e5584071E 1 Reply Last reply Reply Quote 2
            • e5584071E Offline
              e5584071 @Alan Kilborn
              last edited by

              @alan-kilborn , thanks very much. This is exactly what I needed. Have a great day!

              1 Reply Last reply Reply Quote 1

              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