• Login
Community
  • Login

I want to cut a specific range

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
6 Posts 3 Posters 3.7k 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.
  • 김
    김성찬
    last edited by May 6, 2020, 5:37 AM

    111.PNG

    i want red range text delete
    but i don’t know hot to use Regular expressions
    what shoud i do?

    E 1 Reply Last reply May 6, 2020, 10:22 AM Reply Quote 0
    • G
      guy038
      last edited by May 6, 2020, 8:51 AM

      Hi, @김성찬,

      From your picture, I suppose that the following regex S/R should work !

      SEARCH (?-s)^.{56}

      REPLACE Leave EMPTY

      Notes :

      • First the in-line modifier (?-s) means that the regex dot char ( . ) matches a single standard character only and not the line-breaks \r and/or \n

      • Then, from beginning of line ( ^ ), it matches the first 56 characters of any line… and deletes them, as the replacement zone is EMPTY

      Best Regards,

      guy038

      1 Reply Last reply Reply Quote 3
      • E
        Ekopalypse @김성찬
        last edited by May 6, 2020, 10:22 AM

        @김성찬
        just curious, do you know that you can press and hold
        SHIFT+ALT and use the mouse to select a rectangle, which then
        can be easily deleted?

        김 1 Reply Last reply May 7, 2020, 12:58 AM Reply Quote 3
        • 김
          김성찬 @Ekopalypse
          last edited by May 7, 2020, 12:58 AM

          @Ekopalypse
          i know SHIFT+ALT and use the mouse to select a rectangle and delete it
          but select a rectangle sentence is over 400,000 line
          So i needed another way

          E 1 Reply Last reply May 7, 2020, 12:11 PM Reply Quote 2
          • E
            Ekopalypse @김성찬
            last edited by May 7, 2020, 12:11 PM

            @김성찬

            even in this case it would be easy to do it.

            Click on the starting point
            scroll down to the end
            press and hold SHIFT+ALT and click with the mouse to the end point.

            Note, I don’t want you to refuse using regexes,
            just want to make sure that some actions can be done with using it,
            especially when it comes to rectangular selections, easily.

            1 Reply Last reply Reply Quote 3
            • G
              guy038
              last edited by guy038 May 7, 2020, 10:33 PM May 7, 2020, 10:23 PM

              Hello, @김성찬 and All,

              An other and easy solution is to use the Begin/End Select feature !

              • 1 Left click at the very beginning of the first line 0000 90 9F 33 .. .. .., to move the caret to this location

              • 2 Select the option Edit > Begin/End Select

              • 3 Use the Ctrl + End shortcut to get the very end of your hexadecimal dump text

              • 4 Press and hold down the ALT key and left click after the 16th hexadecimal byte of the last line

              • 5 Select, again, the option Edit > Begin/End Select

              => After a while, needed to process 400,000 lines about, as you said, you should notice this big rectangular selection !

              • 6 Simply, press the Delete key

              Voila :-))

              Best Regards,

              guy038

              P.S. :

              If you forget to hold down the ALT key, at step 4 of the method above, you, obviously, get a normal selection of all your text !

              1 Reply Last reply Reply Quote 3
              4 out of 6
              • First post
                4/6
                Last post
              The Community of users of the Notepad++ text editor.
              Powered by NodeBB | Contributors