resources in a lib?

TailBite specific forum

Moderators: gnozal, ABBKlaus, lexvictory

nicolaus
Enthusiast
Enthusiast
Posts: 456
Joined: Tue Aug 05, 2003 11:30 pm
Contact:

resources in a lib?

Post by nicolaus »

Hello,

Can i at resources like icons or so into a lib and if i can do this how i can work with the resources?

Thanks,
nico
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

You can't add windows-resources to a lib.
You can compile the res-script (*.rc) to a res and import this to the
executable (for example with a macro or something else)
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
ABBKlaus
Addict
Addict
Posts: 1143
Joined: Sat Apr 10, 2004 1:20 pm
Location: Germany

Post by ABBKlaus »

Maybe this way :

Code: Select all

ProcedureDLL.l TestLib1()
  ProcedureReturn ?Icon1
EndProcedure

DataSection
Icon1:
IncludeBinary #PB_Compiler_Home+"\Examples\Sources\Data\CdPlayer.ico"
EndDataSection

Code: Select all

Debug CatchImage(#PB_Any,TestLib1())
Post Reply