Delphi Pages Forums  

Go Back   Delphi Pages Forums > Delphi Forum > General

Lost Password?

Reply
 
Thread Tools Display Modes
  #1  
Old 01-08-2007, 08:48 PM
yhchan yhchan is offline
Member
 
Join Date: Oct 2006
Posts: 35
Default TColor Conversion to String/Integer

Can anybody assist on this:-
I am developing a simple form and my form has the color box for user to customize their desire color, so the selected color code I need to save into the registry, so how do I convert from TColor (Input) to String in order to store in the registry, and also retrieve the String from registry convert back to TColor from screen retrieving. Please help.
Reply With Quote
  #2  
Old 01-08-2007, 08:53 PM
davidj davidj is offline
Senior Member
 
Join Date: Jan 2001
Posts: 2,900
Default RE: TColor Conversion to String/Integer

Look in Delphi Help for the function

[DELPHI]ColorToString(...);[/DELPHI]
Reply With Quote
  #3  
Old 01-08-2007, 09:10 PM
davidj davidj is offline
Senior Member
 
Join Date: Jan 2001
Posts: 2,900
Default RE: TColor Conversion to String/Integer

OR to integer

[DELPHI]var

L : Longint;
begin
L := ColorToRGB(Form1.Color);

end;[/DELPHI]
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT. The time now is 06:23 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.