Solved

overwrite the application file from itself

Posted on 2006-07-10
4
337 Views
Last Modified: 2010-04-05
I would like my application to overwrite itself, I want change some setup setting incorporated in the exe application file. I am able to open it for reading with the (fmOpenRead Or fmShareDenyNone) flags, but it fails using fmOpenReadWrite.
0
Comment
Question by:gianluca
  • 2
4 Comments
 
LVL 45

Expert Comment

by:aikimark
Comment Utility
You will need to kick off another task to do this, since the system automatically locks the exe file at the start of execution.
0
 

Author Comment

by:gianluca
Comment Utility
Can I create a new thread to stand-by for the application close, then update the file and close itself ???
0
 
LVL 45

Expert Comment

by:aikimark
Comment Utility
You should create a new process.  A new thread would likely be destroyed when the application (process) terminates.
0
 
LVL 10

Accepted Solution

by:
atul_parmar earned 125 total points
Comment Utility
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Delphi 2010 Export to pdf 2 249
ADO Memory leak with DELPHI 2007 37 153
Thread safe  opinion 7 109
Magic Software info 18 101
A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
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…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

771 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