Forum > General

Can't load resources from a trivial program

<< < (2/3) > >>

I do not use .rc for resources, but all off the $R directives for .lfm resources in my code does not have quotes around the resource name:

{$R checkbox.rc}

The quotes are not mentioned in the language reference either....

Good catch, I didn't see that.

Thanks again for the suggestion.

I was surprised at the results and initially thought (hoped) that the problem was solved.

Eliminating the single quotes allowed my trivial program to build with no issue.

However, when I did the same to the rc lines in the two pascal files that were in the package I got the same fatal error about checkbox.rc suggesting that it was a duplicate.

Thanks to all that helped.

What finally worked was to change the three {$R entries in the package to use the .res files, not the .rc files and remove the single quotes, e.g.,
{$R checkbox.res}

I’ve got no clue why that worked nor why the {$R 'checbox.rc'} approach the developer used was working on their pc, but not mine. If anyone can explain that we'd appreciate hearing the answer.

Having quotes is valid syntax and works for me ({$mode delphi}) but with two arguments; I have lines like

{$R 'shadersrc.res' '..\libraries\common\shadersrc.rc'}

in my .dpr


[0] Message Index

[#] Next page

[*] Previous page

Go to full version