🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #4421

Re: HInstance of Package

#4421
From: Dennis Jones
Date: Mon, 06 Feb 2006 20:16
24 lines
2189 bytes
"Jonathan Benedicto" <invalid@nobody.com> wrote in message
news:43e7a6e8@newsgroups.borland.com...
> Dennis Jones wrote:
> > It's not supposed to.  If you want the bitmap to be in the EXE, you have
> > to
> > add the resource to the EXE's project.  If the resource is in the
> > package's
> > project, then you have to load the bitmap from the package, not the EXE.
>
> I think that this depends on whether the package is linked statically or
> dynamically. A quick Google turned up that you probably need to add
#pragma
> resource "xxx.res" to the component's .cpp file.

Ah, yes, there are some oddities when using resources in packages that are
linked statically, and as I recall, that just might be one of them.  If the
package is linked statically, then it's a matter of figuring out how to make
sure the EXE gets the resource, and I think you're right that pragma is the
solution.  If the package is linked dynamically however, then I think the
only option is to load the resource from the package directly using its
instance handle.

- Dennis
Technical Details
Message-ID: <43e7adba$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!news-peer0-test!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <43e75c95@newsgroups.borland.com> <tf6fu1h9s9onrj42ufffcl79880s3ni630@4ax.com> <43e79cb8$1@newsgroups.borland.com> <43e79f6a@newsgroups.borland.com> <43e7a299$1@newsgroups.borland.com> <43e7a6e8@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,1aa5be8b1f4e1550
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Dennis Jones" <nospam@nospam.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <43e75c95@newsgroups.borland.com> <tf6fu1h9s9onrj42ufffcl79880s3ni630@4ax.com> <43e79cb8$1@newsgroups.borland.com> <43e79f6a@newsgroups.borland.com> <43e7a299$1@newsgroups.borland.com> <43e7a6e8@newsgroups.borland.com>
Subject: Re: HInstance of Package
Date: Mon, 6 Feb 2006 12:16:16 -0800
Lines: 26
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
NNTP-Posting-Host: 204.200.27.7
Message-ID: <43e7adba$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1139256762 204.200.27.7 (6 Feb 2006 12:12:42 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!news-peer0-test!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail