开发者

Is it possible to embed and run exe file in a Delphi executable app?

开发者 https://www.devze.com 2023-03-08 02:21 出处:网络
Resource开发者_StackOverflow社区 files (.RES) accept any kind of binary files but if it is an exe file how can I run it?You would have to extract it as a file to disk and execute it.

Resource开发者_StackOverflow社区 files (.RES) accept any kind of binary files but if it is an exe file how can I run it?


You would have to extract it as a file to disk and execute it.

Although you don't have to extract it to disk, as Cosmin Prund says in a comment, if you don't it requires a lot of hard work.


http://sites.google.com/site/delphibasics/home/delphibasicssnippets/memoryexecutionunit-winxpwinvistawin7

Take a look at this memory execution unit.It allows you to execute an exe from memory without dumping it on disk.


Yes it is possible. There is a Delphi library to do this somewhere on the web, but I cannot for the life of me remember what it's called. It allows you to execute a normal exe file no-matter where it is in memory. So you can load it into a stream, or just embed it in a resource.

I realize that my reply is a bit depressing since i dont remember the name of the library, but at least you now know that it can be done. If you google around for "execute PE exe from memory" and "Delphi" then I'm sure you will find it.


You might want to take a look at Orean's XBundler: http://www.oreans.com/xbundler.php

I use their licensing product (WinLicense) and have been very happy with the product, their support, responsiveness and updates.

In fact, I'm about to buy XBundler so I can ship a dll securely embedded in my exe.

Tom

0

精彩评论

暂无评论...
验证码 换一张
取 消