Board index » delphi » Storing Colors in the registry
Brian Murphy
Delphi Developer |
Brian Murphy
Delphi Developer |
Storing Colors in the registry2004-04-18 10:41:04 AM delphi132 Hi Anyone know how to store a color ( hexadecimal) in the registry for future retrival. Thanks Brian Murphy |
Roel Messiant/Mephy
Delphi Developer |
2004-04-18 08:35:02 PM
Re:Storing Colors in the registry
Hi,
The easiest way i can think up is making a TRegistry component and using the WriteInteger method Reg := TRegistry.Create; try Reg.RootKey := HKEY_CURRENT_USER; if Reg.OpenKey('\Software\MyProgs\ProgName', True) then begin Reg.WriteInteger('PanelColour', Integer(ColourVarName)); Reg.CloseKey; end; finally Reg.Free; end; TColor is compatible with Integer, so it should work Good luck "Brian Murphy" <XXXX@XXXXX.COM>schreef in bericht QuoteHi |
Brian Murphy
Delphi Developer |
2004-04-18 09:52:06 PM
Re:Storing Colors in the registry
That work great.
Thanks Roel Brian "Roel Messiant/Mephy" <XXXX@XXXXX.COM>writes QuoteHi, |