Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to Get a list of valid time zones from windows?

Answer Posted / Rajesh Kumar Sahu

To get a list of valid time zones in Windows using Delphi, you can utilize the TRegistry class. Here's a simple example:nn```delphinprocedure GetTimeZones(const RegPath: string; var Zones: TStringList);nvarn Key, Value: string;n I: Integer;nbeginn Registry.OpenKey(HKEY_LOCAL_MACHINE, RegPath, Key);n Zones := TStringList.Create;n for I := 0 to Key.NumberOfValues - 1 don beginn Key.GetValueName(I, Value);n if (Value = 'TZI') thenn Zones.Add(Key.OpenSubKey(Value).GetValue('DisplayName').StringValue);n end;nend;nn// Usage:nvar TimeZones: TStringList;nGetTimeZones('SYSTEMCurrentControlSetControlTimeZoneInformation', TimeZones);n```

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to Print in Delphi without using the TPrinter Unit ?

1896


How to Create resource files?

1635


How to Flush binary file from disk cache to disk ?

2039


How to Change the owner of a component at runtime ?

1912


How to Change the default width/height of the editor?

1881


How to Retrieve the line number that a memo's cursor is on?

1965


How to Remove drives listed in a TDriveComboBox ?

1935


How to Retrieving the program that is associated with a given extension?

1687


How to Get the time and date in Universal Time ?

1740


How can one prevent a TForm from being moved or resized?

1753


How to Save a QuickReport custom preview to text?

3374


How to Determine the last access time of a given file ?

1817