Menu

Search for exactly 2 brackets...

Micha
2014-01-30
2014-01-30
  • Micha

    Micha - 2014-01-30

    Hey,

    I'd like to find rows containing exactly 2 square brackets and put " /ss" at each end.

    For example:
    A[QJ]J
    [KT][T9]
    [K87]K

    should become:
    A[QJ]J /ss
    [KT][T9]
    [K87]K /ss

    Thanks a lot for any help!

     
  • GerdB

    GerdB - 2014-01-30

    Hi Micha,

    use search/replace in RegEx-Mode with the following Search-Expression:

    "(^\w*\[\w*]\w*$)"
    

    (without quotation marks of course) and replace with

    "\1 /ss".
    

    You may want to take a look at http://www.boost.org/doc/libs/1_49_0/libs/regex/doc/html/boost_regex/syntax/perl_syntax.html for more Information about regular Expressions used in Notepad++.

    regards
    Gerd

     
  • Micha

    Micha - 2014-01-30

    Great, big thanks :)