procedure TForm1.Button1Click(Sender: TObject);
var
MyIcon : TIcon;
begin
if Opendialog1.Execute then
begin
MyIcon := TIcon.Create;
MyIcon.Handle := ExtractIcon(hInstance, PChar(Opendialog1.filename),0);
DrawIcon(Form1.Canvas.Handle, 10, 10, MyIcon.Handle);
MyIcon.Free;
end;
end;
Sabtu, 10 November 2007
Extract an Icon From Application
Langganan:
Comment Feed (RSS)
|