Community
    • Login

    Notepad++ file format looks different when opened in Windows Notepad

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    3 Posts 2 Posters 1.3k 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.
    • miltonM
      milton
      last edited by

      A text file opened in Windows 7 Notepad looks like a continuous line without end of lines i.e. no Word Wrap. However, when I open the file in Notepad++, all contents are in separated lines.

      For example:
      In Window 7 Notepad:
      clientproto udpdev tundh dh2048.pemca

      In Notepad++:
      client
      proto udp
      dev tun
      dh dh2048.pem
      ca

      How can I save the file format in Notepad++ style?
      Now if I save the file in Notepad++, but when I open the same file in Windows 7 Notepad, it’s in continuous line no “Word Wrap” or EOL style.

      Thanks,
      Milton

      PeterJonesP 1 Reply Last reply Reply Quote 0
      • PeterJonesP
        PeterJones @milton
        last edited by

        @milton ,

        My guess is that the file is using “unix”-style newlines (LF) rather than Windows newlines (CR LF), so MS Notepad doesn’t show them on separate lines. You can tell, because when you load in Notepad++, it will show “Unix (LF)” on the status bar, instead of “Windows (CR LF)”.

        If that’s what Notepad++ you want to save the file in a way that other applications (like your Win7 MS Notepad) will recognize the line endings, you can either right click on the “Unix (LF)” and change it to “Windows (CR LF)” then save, or use Edit > EOL Conversion > Windows (CR LF)

        (When I tried to replicate in Win 10 22H2 19045, MS Notepad was able to see the LF or even ancient-mac-style CR newlines and still show as separate lines, but since Win7 is a decade out of date, it wouldn’t surprise me if it was lacking that feature.)

        miltonM 1 Reply Last reply Reply Quote 3
        • miltonM
          milton @PeterJones
          last edited by

          @PeterJones

          Yes, you are correct.
          Thank you so much for the clarification and instruction.

          The issue is solved. Thank you

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          The Community of users of the Notepad++ text editor.
          Powered by NodeBB | Contributors