You are faced with what I consider to be an “error” in the TWriter.WriteString and TWriter.ReadString methods. These two methods are internally used by Delphi to move your TLabel.Caption from a real live object at design time to a DFM file, and then back to a live object at runtime.
If you look at the code for these two routines, you will notice (in shock, I suppose) that the actual material that enters the stream is converted to Unicode using the default code page for the operating system! This thin and dandy, as long as the code page used on the development machine, exactly matches the code page used on the test machine, and they probably don't match, and, most likely, why you get the error. Please note that the EASTEUROPEAN_CHARSET parameter that you set for Caption on the form is absolutely irrelevant, because the TWriter.WriteString method does not know about it!
I have a bug report on this issue in QC, it has existed for many years ... They probably consider it "by design", but I do not think it is a very good design.
The solution I would recommend is a quick transition to Delphi 2010. I am a Delphi developer in Romania and I had many, many problems with such things, but now it's all in the past because Delphi 2010 is UNICODE, so I have more No need to worry about code page conversions.
If you cannot switch to Delphi 2010, you may need to “crack” the Classes.pas file and modify the TReader.ReadString procedure to always perform the conversion using the code page, and not by default.
Cosmin prund
source share