Windows notepad not supporting newline character '\n'

后端 未结 4 1584
陌清茗
陌清茗 2020-11-29 11:14

From my iPhone application I\'m outputting data from text to a file. When opened with windows notepad, the data is all on one line and where there should be a new line a blo

4条回答
  •  天命终不由人
    2020-11-29 11:58

    Recently ran into this issue and I was convinced that it was my code which is doing this but turns out Notepad has problems rendering the file in the right format.

    How do we fix this?

    There is no fix available of this behavior of notepad but here is a list of workarounds that can be performed in order to read the contents correctly.

    Workaround

    1. You can use Windows WordPad to open the file or just paste the contents of the file into WordPad and back into Notepad . This should fix the problem .

    2. You can also use Notepad++ to open the files which is a third-party text reader and can be installed on a windows system.

    3. Microsoft recently (October 2018) announced that Notepad has been fixed in Windows 10 version 1809 so updating your system to windows 10 should resolve this issue (Windows versions before 1809 are impacted)

    Microsoft fixed this after 33 years !!! Gee thats a long time to fix the issue aint it ?

提交回复
热议问题