?
Solved

Embeding exe file

Posted on 2000-02-26
5
Medium Priority
?
135 Views
Last Modified: 2010-05-18
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
Comment
Question by:eruj
5 Comments
 
LVL 7

Expert Comment

by:ahalya
ID: 2561933
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
 
LVL 1

Expert Comment

by:XAN
ID: 2562315
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
 
LVL 6

Accepted Solution

by:
DrDelphi earned 200 total points
ID: 2562501
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
 
LVL 5

Expert Comment

by:Gwena
ID: 2563593
Hi DrDelphi :-)

  Where is your webpage?
0
 
LVL 6

Expert Comment

by:DrDelphi
ID: 2563630
www.drdelphi.com

Search for "Resource"
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
This Micro Tutorial will teach you how to add a cinematic look to any film or video out there. There are very few simple steps that you will follow to do so. This will be demonstrated using Adobe Premiere Pro CS6.
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses
Course of the Month14 days, 2 hours left to enroll

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question