How to repalce newlines to other characters with Extended Search



  • I hope to replace in the following text with

    X41562005-01\n
    X7136\t2012-01\n
    X4151\t2001-02\n
    X4159\t2005-01\n



  • Correction of the Question:

    I hope to add <tab> and a string after every end of lines in the following text:

    X4156 2005-01
    X7136 2012-01
    X4151 2001-02
    X4159 2005-01

    like, for example,

    X4156 2005-01 a
    X7136 2012-01 a
    X4151 2001-02 a
    X4159 2005-01 a

    Then I used the feature of Extended Replace: In Replace Window, setting
    Find what: \n
    Replace with: \ta
    Search mode: Extended

    But the result is as follows:

    X4156 2005-01 a
    aX7136 2012-01 a
    aX4151 2001-02 a
    aX4159 2005-01 a

    Why? What should I do?



  • @Shima-Hisaharu

    what you have posted and what you did describe doesn’t match.

    If you want to have it added you need to replace with \n\ta

    But from what you’ve posted as result you want to insert it in front of \n
    which means you need to replace with \ta\n.

    Find is, for both, like you already did \n

    Cheers
    Claudia


Log in to reply