Computing.Net > Forums > Programming > Read file concatenated to the EXE

Computing.Net: Over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to sign up now, it's free!

Read file concatenated to the EXE

Reply to Message Icon

Original Message
Name: alexanrs
Date: June 9, 2006 at 11:44:31 Pacific
Subject: Read file concatenated to the EXE
OS: Windows XP/ 98SE
CPU/Ram: Athlon 64 3000+ / 512 MB
Comment:

I like to program as a hobby, and I'm currently coding a test application for DOS in OpenWatcom that uses a small VESA windowing library I wrote. This test application uses a wallpaper, an pattern image that is shown inside a window and an icon.

Until recently I was reading these files directly (test.bmp, stest.bmp and test.ico), but now I concatenated them all using a "COPY /b test.bmp+stest.bmp+test.ico test.res" and I am reading them as a stream (my image classes have both a ReadFile and a ReadStream function). It is working OK, but I'd like to have this resource concatenated to the EXE file. I uploaded the test here (yeah, the clipping system is buggy):
http://www.geocities.com/alexanrsousa/files/bin.zip

I know it is possible because I've seen some applications doing such a thing, like the PLANY.EXE included in Arachne (I did not find plany's source code, though Arache itself is open source), in which you can do something like "COPY/B PLANY.EXE+SOUND.SND SOUND.EXE" to create an "executable" sound file.

Does someone know how to do this? I'd really appreciate to learn how to do it.


Report Offensive Message For Removal








Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home








Do you have your own blog?

Yes
No
I did before
I will soon


View Results

Poll Finishes In 2 Days.
Discuss in The Lounge
Poll History




Data Recovery Software