Forum Discussion

DennisGalon's avatar
DennisGalon
Copper Contributor
Apr 05, 2024

Find And Replace to Add Line Breaks within Cells

Within a Cell Alt + Enter introduces an invisible Line Break or New Line Code.
Believe that code is Char(10)

 

How do I use Find & Replace to Find characters (let's say $$) and replace this with the Line Break code???

12 Replies

  • GraceAA's avatar
    GraceAA
    Copper Contributor

    In case anyone else stumbles on this question, this is the answer for an in-cell line break

    Ctrl+H to bring up the Replace popup

    Find What = ,

    Replace With = here press "Ctrl+J"

    Press Replace

    • Gracey56's avatar
      Gracey56
      Copper Contributor

      Excel does not recognise "Ctrl J" in the find/replace dialog box, in Word you can enter "special characters" there is no option for this in Excel

       

      • I don't know about other platforms, but Excel for Windows does recognize Ctrl+J in the Find/Replace dialog. You should see the insertion point (the blinking vertical bar) disappear except for one pixel.

    • SnowMan55's avatar
      SnowMan55
      Bronze Contributor
      I'm not familiar with Excel for Mac shortcut keys, but how about trying this? In a spare cell, place the formula =CHAR(10) and then copy the cell, and then immediately paste that into the same cell using a Paste Values. Then you could recopy the cell and use it in the Find and Replace dialog.
      • RobertR2060's avatar
        RobertR2060
        Copper Contributor
        Almost worked. Instead of a line break, it entered " "

        I also tried =CHAR(13) as I saw that some versions of Excel for Mac used that insted of =CHAR(10).

        Thank you.

Resources