Is the document totally empty or is it the Lua script app which is blank ?
Sorry, I looked again today and saw that it's really empty. I have a TouchPad Nspire, so Levak is probably right that there's too little RAM. That means it should only be a problem if I save the document while I'm for example in the document browser, because the script isn't blank before I save it, only when I open it again later.
Are you trying to open a Lua script that has a consequent size (like hundreds of KB) ?
The tns is only 23KB, but its Lua code Chockosta posted is 250KB.
Is there any way to reduce the RAM usage of the OS or something?