Examples Delphi

Question:
I would like to know which country or language my program is running in? How can I pick this information from Windows? (control panel settings)
Answer:
Easy - see the code below (Delphi 5) - it returns 'English (United States)' here.

procedure TForm1.FormCreate(Sender: TObject);
begin
// this returns 'English (United States)' here..
Caption := Languages.NameFromLocaleID[GetThreadLocale];
end;