Solved

Embeding exe file

Posted on 2000-02-26
5
123 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
Comment Utility
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
Comment Utility
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 50 total points
Comment Utility
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
Comment Utility
Hi DrDelphi :-)

  Where is your webpage?
0
 
LVL 6

Expert Comment

by:DrDelphi
Comment Utility
www.drdelphi.com

Search for "Resource"
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

772 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now