Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 138
  • Last Modified:

Embeding exe file

Hello!

Is it possible to embed an external executable file in my application, so that there would be only one (the main)executable file?

Thanks
0
eruj
Asked:
eruj
1 Solution
 
ahalyaCommented:
You can make your EXE more like a "Self Extracting" exe, and extract all support files when your exe is run.

if you like this approach, and would like some source, then I can email one of my similar project to you.
0
 
XANCommented:
of course. you can use it as resource.

other way ;) you can have one executable file, and other - any other type, that actually is external executable (may be only you will know about the nature of last ;)
0
 
DrDelphiCommented:
This example assumes that you have created a resource file named "Resfile.res" with the executable and named it "EXE". See my webpage for detials on how to do this if you are not sure.


{$resource 'resfile.res'}


var Stream:TresourceStream;
begin
     stream:=Tresourcestream.Create(Hinstance,'EXE','RT_RCDATA');
     stream.SaveToFile('Zoomer2.exe');
     Winexec('Zoomer2.exe',sw_ShowMaximized);
end;



Good luck!!

0
 
GwenaCommented:
Hi DrDelphi :-)

  Where is your webpage?
0
 
DrDelphiCommented:
www.drdelphi.com

Search for "Resource"
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now