Save project error

Last night I saved the project and I am sure I read that it had been correctly saved. Today I take it back and find only a small part of the code was saved. What may have happened?

I spent a day rewriting everything on a new project. This time also saving in .aia file on the PC. This morning I go to load the project and find only the complete designer part but only a small part of the blocks. Loading from the .aia file happens the same. But does it just happen to me? Can there be any controls that confuse loading the project? But above all, how can I load the whole project?

I discovered the problem. I had defined a string constant by copying/pasting from a text containing the 06 hex. This produced an incorrect XML into the .aia file. I hope it will be useful to someone else.

Please explain that in more detail.

I have to transmit the byte 06 in hex (ACK) on a bluetooth client, so I tried (and it works) to create a text file with the character x’06. Then I pasted this character into the bluetooth.sendtext text. When saving the project, the .aia file contains the screen1.bky file with an incorrect xml tag which interrupts the subsequent loading of the project blocks.
I tried to replace the character with any ascii char in Screen1.bky file and to rebuild the .aia file with winzip, but without success. Any suggestions? I would like to avoid starting all over again. Tks

Solved. After modifying the .bky file, you have to use Winrar (no winzip or 7z) to create the .zip again and rename it to .aia.

This is similar to!msg/mitappinventortest/BGnx9UnMMig/dcusUJvSCwAJ
from the AI2 Issues FAQ
FAQ Section: App Inventor Issues
3rd link from bottom.