Search results for 'ColorToHtml'. 1 post(s) found.

  1. 2007/09/11 TColor to HTML color
2007/09/11 08:00

TColor to HTML color


Put a TColorDialog (ColorDialog1), a TLabel (Label1) and a TButton (Button1) in your form, and assign the Button1.OnClick procedure as follows:

procedure TForm1.Button1Click(Sender: TObject) ;

  function ColorToHtml(DColor:TColor):string;
  var
    tmpRGB : TColorRef;
  begin
    tmpRGB := ColorToRGB(DColor) ;
    Result:=Format('#%.2x%.2x%.2x',
                   [GetRValue(tmpRGB),
                    GetGValue(tmpRGB),
                    GetBValue(tmpRGB)]) ;
  end; {function ColorToHtml}

begin
  if ColorDialog1.Execute then
   Label1.Caption:=ColorToHtml(ColorDialog1.Color) ;
end;
Trackback 12 Comment 0

Trackback : Cannot send a trackbact to this post.

  1. Subject Free animal sex pictures free.

    Tracked from Free animal sex movies. 2009/02/11 16:10 delete

    Animal sex with girls. Gay animal sex. Animal sex movies. Free animal sex videos. Animal sex videos. Animal sex pics. Free animal sex. Animal sex chat. Animal sex.

  2. Subject Lipitor.

    Tracked from Lipitor and muscle pain. 2009/03/07 08:17 delete

    Generic lipitor. Lipitor effects gall bladder. Benefits of lipitor. Can aspirin be taken with lipitor and metfromin. Lipitor.

  3. Subject Valtrex side effects.

    Tracked from Valtrex. 2009/04/03 18:11 delete

    Valtrex no prescrition. Side effects of valtrex.

  4. Subject Codeine.

    Tracked from Codeine source of. 2009/04/24 10:06 delete

    Extract codeine. Codeine. Codeine phosphate.

  5. Subject Codeine.

    Tracked from Codeine facts. 2009/05/03 21:03 delete

    Apap codeine. 222 isolate codeine. Extract codeine. Acetaminophen-codeine 3. Codeine.

  6. Subject Buy tramadol.

    Tracked from Tramadol. 2009/05/27 08:51 delete

    Tramadol hcl. Tramadol. Tramadol no rx 180 pills.

  7. Subject Valium prescription online.

    Tracked from Valium liquid form. 2009/06/01 06:55 delete

    Side effects of valium. Valium.

  8. Subject Buy xanax online.

    Tracked from Can you buy xanax without a prescription. 2009/06/17 08:01 delete

    Half-life of xanax. Xanax addiction. Xanax.

  9. Subject Valium canada.

    Tracked from Valium. 2009/06/17 15:08 delete

    Valium cash on delivery. What is valium used for. Valium no prescription. Valium metabolism. What does valium look like. Valium liquid form. Valium.

  10. Subject different money making ideas

    Tracked from moneyideas 2010/01/29 05:19 delete

    moneyideas

  11. Subject different money making ideas

    Tracked from moneyideas 2010/01/29 14:04 delete

    moneyideas

  12. Subject different money making ideas

    Tracked from moneyideas 2010/01/31 16:39 delete

    moneyideas