Article View: borland.public.delphi.language.objectpascal
Article #59Re: Loading Stock Bitmaps
From: Charles Appel
Date: Sun, 25 Jan 2004 14:52
Date: Sun, 25 Jan 2004 14:52
19 lines
1740 bytes
1740 bytes
"David" <dwilbourn@hotmail.com> wrote in message news:4013b559$1@newsgroups.borland.com... > > I am trying to load one of the Stock bitmaps - the close 'X' in the top left corner of a window - into a bitmap. I have found some examples of how to do it for VB but can't get it to work on Delphi. VB uses the LoadBitmapBynum API call but the few clues I have found in Delphi indicate that the .LoadFromResourceID method is the way to go. But I can't get either way to work. Does anyone have any pointers to what I should be doing? Place the graphic in a resource file. Give it a meaningful name - for example: CLOSE_X. Include the resource file in your form unit. Use a call similar to this one: MyImage.Picture.Bitmap.LoadFromResourceName(hInstance,CLOSE_X); Charles Appel
Technical Details
Message-ID:
<4013d83a@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshosting.com!news-xfer1.atl.newshosting.com!203.109.252.33.MISMATCH!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<4013b559$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 109d30,565e38e074acddf5 X-Google-Attributes: gid109d30,public X-Google-ArrivalTime: 2004-01-25 06:54:35 PST From: "Charles Appel" <charlesappel@mindspring.com> Newsgroups: borland.public.delphi.language.objectpascal References: <4013b559$1@newsgroups.borland.com> Subject: Re: Loading Stock Bitmaps Date: Sun, 25 Jan 2004 09:52:42 -0500 Lines: 21 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 NNTP-Posting-Host: 209.86.130.223 Message-ID: <4013d83a@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1075042362 209.86.130.223 (25 Jan 2004 06:52:42 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshosting.com!news-xfer1.atl.newshosting.com!203.109.252.33.MISMATCH!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail