Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

argh --one of those contact borland errors

Posted on 1999-01-20
4
Medium Priority
?
157 Views
Last Modified: 2010-04-06
hi,
i am using bitmaps etc from a res file.there was no prob
with calling the bitmaps (forms background pictures)from the res file when testing on a dummie project with one form,but when i move to main project i get the errors below .the error is duplicated for each form.
ERROR:(0): TYPE 2 (BITMAP),ID BGROUND:.
ERROR:(0): File StockRes.Res resource kept; File StockRes.Res resource discarded..

i think it is because i am using the same bitmap for background on 14 forms,i am calling the bitmaps on formcreate as it wouldnt work on form paint?
any ideas how i can call bitmaps from resource without this error occurring would be appreciated
Regards Barry
0
Comment
Question by:inthe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 12

Accepted Solution

by:
rwilson032697 earned 400 total points
ID: 1362644
Are you including the resource file in each form unit? If so this will be causing the problem.

In any event, the resource file should only be included into the project once. The best place is in the DPR file:

I assume you include it like this:

{$R MyResources.Rec}

Cheers,

Raymond.
0
 
LVL 17

Author Comment

by:inthe
ID: 1362645
wahey Thanks a lot for answer
no need to call borland any more that was the problem, i put {$R StockRes.Res} in each form not just main one,when i put it only in main one it works great.
but why can this {$R *.DFM} be ok then? isnt it still be loaded on each form .
Regards Barry
0
 
LVL 12

Expert Comment

by:rwilson032697
ID: 1362646
Barry: The {$R *.DFM} is really just a short hand notation for {$R MyForm.DFM}, so only the DFM for that one form is included at that point. Confusing I know.

Cheers,

Raymond.

0
 
LVL 17

Author Comment

by:inthe
ID: 1362647
ahh of course ,the way i was thinking it would be {$R *.DPR}

Anyway thanks again :-)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question