`
Windows API: Using Resources to link data files to EXE 2005-01-17 -- Jim Kane Newsgroups: softvelocity.clarion.language > Clarion allows compiling in image files using the tilda as a file prefix, > such > as '~icon.ico'. Is there any way to do this for data files? > > I have an app with many static files and I'm interested in compiling them > all > together as a single exe. I wish to eliminate the dependency of having > multipe > files and just have one file that is there or not and will therefor be > guarenteed to work if that one file is on the system. Yes, I do that often. I just rename the file as a bmp and add it as an image. Then at run time I use findresource, loadresource, lockresource and sizeofresouce. With that info I can write the data to disk again at run time. In my case the files are actually word perfect files but it would work for tps files or just about anything else. This month in clarion mag is an article about font resources and it has all the info you need for reading resources at run time. jim kane Printed November 21, 2024, 11:28 am This article has been viewed/printed 35202 times. Google search has resulted in 10 hits on this article since January 25, 2004. |