Hi,
I'm using Delphi 5. In order to programmtically change the local language my PC is using I have looked on the function SetThreadLocale, and after surfing the web I was recommended to start my application in this way in order to obtain the greek language:
Delphi-Quelltext
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18:
| program Mp3_TagEdit_Prj;
uses Forms, Windows, ** SysUtils, ** MainUnit in 'MainUnit.pas' ;
{$R *.RES}
begin SetThreadLocale($0408); ** GetFormatSettings; ** Application.Initialize; **
Application.CreateForm(TMainForm, MainForm); Application.Run; end. |
(the programlines with ** is added to my standard programstart)
But the problem is that this does not functionate. When I try to show the content of a folder in FileListBox everything works fine as long as the filename is made up of english characters, but if the folder contains filenames mad up of greek characters I get an I/O error 123 men which means that the file cannot be opened - in another way FileListBox is not able to read these greek filenames.
In my program all fonts are set to GREEK_CHARSET.
But I still program in Delphi 5, and I wonder if I would get rid of this problemg by using the newest Delphi 2005 instead ??
I think it is peculiar that my Windows XP can read greek filenames without problems. Likewise my mp3-program
(MediaMonkey) can read these files too without any problems
[the following "labels" from windows XP is my own translation to english from the danish version and is probably not exactly right]
If I go in Windows XP "Control Panel" and open "International and language settings", and then under the tab "Advanced" under "Language with non-unicode programs" set the language to Greek and RESTART my PC
- then my FileListBox can read the greek filenames.
But as mentioned earlier - I would like to be able to do this programmatically, and not by change a setting in Windows and restart my PC.
So finally my question is:
Do you think thar using Delphi 2005 instead of Delphi 5 will solve the problem?? Or could there be any other solutions/suggestions to solve the problem??
Hoping very much for an answer
KindRegards
Lars
Moderiert von
Christian S.: Added delphi tags