Click here to Skip to main content
15,885,309 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
i need code to read image in delphi
Posted
Updated 27-Dec-11 7:38am
v2
Comments
Smithers-Jones 27-Dec-11 17:01pm    
Not a question. Reported.

Did you try to Google[^]? Lots of potential hits, like:
- http://mc-computing.com/languages/delphi/images.html[^]
- http://www.delphidabbler.com/tips/21[^] and so on...
 
Share this answer
 
Comments
Espen Harlinn 30-Dec-11 9:27am    
Fair reply, my 5
Wendelius 30-Dec-11 10:22am    
Thank you :)
Delphi
procedure LoadAnImage()
var 
  OleGraphic: TOleGraphic; 
  fs: TFileStream; 
begin 
  try 
    OleGraphic := TOleGraphic.Create; 
    fs         := TFileStream.Create('C:\...\image.gif', fmOpenRead or fmSharedenyNone); 
    OleGraphic.LoadFromStream(fs); 
    SampleImage.Picture.Assign(OleGraphic); 
  finally 
    fs.Free; 
    OleGraphic.Free 
  end; 
end;


Google is your friend.
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900