How to embed a resource programatically?

Say you have an exe file located in "C:\test.exe" (to be used as a resource). When I run this app it will check for "test.exe" file and embed into itself.

So the next time I run the app it will have the "test.exe" embedded and won't require the "exe" located in "C:\test.exe".

OR say I have an app (single .exe file) in which there's an empty embedded resource "test.txt". How can I write the contents of "C:\test.exe" to that empty resource from another app? Or probably create a new resource inside that already complied app?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.