Community
    • Login

    How to separate specific text with notepad?

    Scheduled Pinned Locked Moved General Discussion
    22 Posts 4 Posters 14.0k 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.
    • guy038G Offline
      guy038
      last edited by guy038

      Hello, @yuly-pmem, @ani-rodet, @terry-r and All,

      Ah OK ! So, here are, below, all the regexes to achieve the suppression of 1 or 2 columns, from an original 3-columns table, separated with colons ( : )

      Let’s imagine the initial 3-columns table, below :

      cell A1:cell B1:cell C1
      cell A2:cell B2:cell C2
      cell A3:cell B3:cell C3
      

      Then :

      • With the regex S/R :

      SEARCH :[^:\r\n]+$

      REPLACE Leave EMPTY

      Only columns A and B remain :

      cell A1:cell B1
      cell A2:cell B2
      cell A3:cell B3
      
      • With the regex S/R

      SEARCH (?-s):.+(?=:)

      REPLACE Leave EMPTY

      Only columns A and C remain :

      cell A1:cell C1
      cell A2:cell C2
      cell A3:cell C3
      
      • With the regex S/R :

      SEARCH (?-s)^.+?:(?=.+:)

      REPLACE Leave EMPTY

      Only columns B and C remain :

      cell B1:cell C1
      cell B2:cell C2
      cell B3:cell C3
      
      • With the regex S/R :

      SEARCH (?-s):.+$

      REPLACE Leave EMPTY

      Only column A remains :

      cell A1
      cell A2
      cell A3
      
      • With the regex S/R :

      SEARCH (?-s).+:(.+):.+

      REPLACE \1

      Only column B remains :

      cell B1
      cell B2
      cell B3
      
      • With the regex S/R :

      SEARCH (?-s)^.+:

      REPLACE Leave EMPTY

      Only column C remains :

      cell C1
      cell C2
      cell C3
      

      Cheers,

      guy038

      1 Reply Last reply Reply Quote 3
      • yuly pmemY Offline
        yuly pmem
        last edited by

        @guy038 said:

        @terry-r

        I am very grateful for your help friends (guy038, terry), they are the maximum
        thank you teachers

        they work perfectly

        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