Question Words inside Notepad are being deleted

Endre

Reputable
Hello!

I've observed a pretty strange thing:

I have lots of text files created with Notepad app of Windows 11, and from time to time when I re-open them, I see that the last written words inside the files are missing. As if someone started deleting them from the back towards the front.

Does anyone have a solution to this?
Or am I the only person experiencing it?
 

Ralston18

Titan
Moderator
Just curious here....

Which version of Notepad?

And the text files are solely created/manually typed into Notepad - correct?

Is it always the same number of words or characters that are missing?

When the text file is first saved check the file size. Then later, if words are missing, check the file size again.

Import/copy in some other test text file to Notepad. Save as usual and determine if the imported file "loses" words.
 

USAFRet

Titan
Moderator
Hello!

I've observed a pretty strange thing:

I have lots of text files created with Notepad app of Windows 11, and from time to time when I re-open them, I see that the last written words inside the files are missing. As if someone started deleting them from the back towards the front.

Does anyone have a solution to this?
Or am I the only person experiencing it?
After entering NEW text, did you save the file before closing?

Notepad does not have any autosave function.
 

Endre

Reputable
does it happen every time?

say you make a file and then save it. are the contents gone next time you open it?

is it synced to onedrive? maybe its not saving the last changes?

No. It doesn't happen everytime.
Only from time to time.

For instance, if I create a notepad text file that contains a license key of a program, the infos will be saved inside the file, but then, months later if I re-open the file, some of the words will be missing.
(I've observed many of such notepad files having missing words).

Words also disappear immediately after a restart of the PC if I populate an entire row with a long line made out of continuous dashes.

No it is not synced to OneDrive.
 

Endre

Reputable
Just curious here....

Which version of Notepad?

And the text files are solely created/manually typed into Notepad - correct?

Is it always the same number of words or characters that are missing?

When the text file is first saved check the file size. Then later, if words are missing, check the file size again.

Import/copy in some other test text file to Notepad. Save as usual and determine if the imported file "loses" words.

Hello!

•The Notepad is the default one in Windows 11.

•I don't know if it's always the same number of words or characters missing.

•Yeah, I'll pay attention to see if the size of the file is changing.

•Yeah, I'll make some tests to import text into Notepad, save it, then re-open it to see if it loses words.
 

Colif

Win 11 Master
Moderator
what drive are they saved on? I would perhaps check its health if its always the same drive.

I have had drives that lose space before but i don't think I have noticed files ever losing data. Only examples of that I have seen anywhere are YouTube videos where people buy 256gb USB sticks for $15 that are clearly lies, as the cost is too low for what you supposedly get, and the USB drive just rewrites over itself.
 

Endre

Reputable
what drive are they saved on? I would perhaps check its health if its always the same drive.

I have had drives that lose space before but i don't think I have noticed files ever losing data. Only examples of that I have seen anywhere are YouTube videos where people buy 256gb USB sticks for $15 that are clearly lies, as the cost is too low for what you supposedly get, and the USB drive just rewrites over itself.

Hello!

The files are always on partition D.
Partition D is on a RAID_0 volume (3x Samsung 970 Pro 1TB M.2 NVMe SSDs).
I have "0" issues with any other program.

Just a few moments ago:
I've re-edited a Notepad file; I've re-opened it and everything was fine.
Then, I restarted the PC and when I re-opened the file, the new inserts were no longer there!
 

Colif

Win 11 Master
Moderator
can't run magician on raid drives.

If you want to recover notepad file that is unsaved after a restart, please go to C:\Users\USERNAME\AppData\Roaming to find if unsaved text file located there.
https://docs.microsoft.com/en-us/answers/questions/113230/i-lost-a-very-important-file.html

That makes me wonder. Wonder if partial copies of the files are saved to roaming, but why would it copy them as saved versions. I have had sync mess with my desktop before but not files (who knows, maybe). Could explain why it happens after a restart/logon process as that is when PC checks these things.

I wonder if its account sync. I thought they removed that in Win 11.
have a look in settings/accounts/Windows Backup.
see what shows next to the options here.

maybe disable them and retrace steps and see if it makes any difference.
 

Ralston18

Titan
Moderator
When the Notepad documents are created is there any sort of a constant or standard ending - some word(s) or other string of characters?

What I am thinking is that some Control code is inadvertently becoming part of the text.

E.g.:

http://metadataconsulting.blogspot.com/2019/06/Notepad-Control-Characters-Explained.html

Take a look for any unexpected control codes.

Use a copy of any problem text file or a copy of a text file without problems.

Doing so will allow you to "edit" on the fly and tinker about a bit....

If things go astray with the file - then just make another copy to work on.
 

Endre

Reputable
Hello!

After a pretty long time, I finally discovered the root of this issue:
The issue was caused by the ReFS partition format!
(ReFS is supposed to be a more advanced file system 😕).

With other words, whenever I edited a notepad text file, writing more into it, then save it; after the PC restart, the file would keep the previous form (everything that I edited would be erased).
My workaround was to save the file with a different name. This way it was keeping the edited, saved version.

NTFS partitions do not have this issue!

So, after doing many tests on both ReFS and NTFS partitions that confirmed the truth of this matter, I re-formatted my D partition as NTFS.
Problem solved!
 

Colif

Win 11 Master
Moderator
Are you running a server os? nvm, seems its in 10/11 but only as part of storage spaces.

https://docs.microsoft.com/en-us/windows-server/storage/refs/refs-overview

its 5 years old so although its newest they made, its no baby

its not a replacement for NTFS yet
All these features sound pretty good, but you can’t just switch to ReFS from NTFS. Windows cannot boot from a ReFS file system, and requires NTFS.


ReFS also omits other features NTFS includes, including file system compression and encryption, hard links, extended attributes, data deduplication, and disk quotas. However, ReFS is compatible with a variety of features. For example, while you can’t perform encryption of specific data at the file system level, ReFS is compatible with full-disk BitLocker encryption.


Windows 10 does not allow you to format any old partition as ReFS, either. You can currently only use ReFS with Storage Spaces, where its reliability features help protect against data corruption. On Windows Server 2016, you can choose to format volumes with ReFS instead of NTFS. You might want to do this for a volume you plan on storing virtual machines on, for example. However, you still can’t use ReFS on your boot volume. Windows can only boot from an NTFS drive.
https://www.howtogeek.com/311840/what-is-refs-the-resilient-file-system-on-windows/

https://www.n-able.com/blog/refs-vs-ntfs

probably too much info: https://www.sciencedirect.com/science/article/pii/S266628172030010X
 
Last edited:
  • Like
Reactions: Endre

Endre

Reputable
Are you running a server os? nvm, seems its in 10/11 but only as part of storage spaces.

https://docs.microsoft.com/en-us/windows-server/storage/refs/refs-overview

its 5 years old so although its newest they made, its no baby

its not a replacement for NTFS yet

https://www.howtogeek.com/311840/what-is-refs-the-resilient-file-system-on-windows/

https://www.n-able.com/blog/refs-vs-ntfs

probably too much info: https://www.sciencedirect.com/science/article/pii/S266628172030010X

Yeah.

The thing is that ReFS, by "helping against data corruption", seemed, to me, like the better option for all storage partitions. But for me, it's not!

The reality is that, Notepad was the only program that I had issues with, while using ReFS.

*I'm using Win11 Enterprise.
 

Colif

Win 11 Master
Moderator
For some file features are supported for NTFS but not for ReFS, we can't make sure that files which can be copied to NTFS can also be copied to ReFS.
https://social.technet.microsoft.co...le-system-limitation-refs?forum=winserver8gen
article linked in solution no longer there, its from 2012.

It is hard to find anything really on ReFS & notepad, it might be the txt file format, and how its treated on ReFS.

you might have needed to run this: https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/refsutil

so you have a storage pool of 3 drives? and the only thing it loses is info in notepad documents? that is strange. I can't find anything similar.

if they weren't in a pool I would check drive health. you can't while they in raid.
 
Last edited:

Endre

Reputable
https://social.technet.microsoft.co...le-system-limitation-refs?forum=winserver8gen
article linked in solution no longer there, its from 2012.

It is hard to find anything really on ReFS & notepad, it might be the txt file format, and how its treated on ReFS.

you might have needed to run this: https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/refsutil

so you have a storage pool of 3 drives? and the only thing it loses is info in notepad documents? that is strange. I can't find anything similar.

if they weren't in a pool I would check drive health. you can't while they in raid.

Hello again!

Yes, I do have 3x Samsung 970 PRO 1TB M.2 NVMe PCIe 3.0 RAID_0 volume (Local Disk C + D).
Local Disk D was previously ReFS format. Now it's NTFS.

Yes, the only issue I ever had was with the Notepad.
All of the other programs worked normally.

If there would be any issue with one of my drives, I should have those problems while being on NTFS too.
 

Endre

Reputable
still seems odd. Its backwards that a file system set up for servers would lose info.

Do you make different versions of the file? I can find cases where ReFS removed files as they were corrupted, so are we sure its not just another version of the file it opens the 2nd time?
https://forums.veeam.com/veeam-back...ed-from-the-file-system-namespace-t69132.html

Hello again!

The situation of saving a Notepad text file on a ReFS Win11 partition is this:

1. I create a notepad file having some text infos inside/ I save the file/ (everything is fine).

2. The next day: I open the text file, edit the content/ Save the file.
If I re-open the file, the changes that I've made are there.

3. After a restart of the PC, the text file goes back to the previous, un-edited form!

PS:
The same issue accured even after a clean re-install of Windows!

SOLUTION:
Format the partition as NTFS.
Problem solved.

#NTFS_rocks! #ReFS_sucks!