Solved

Multiple instances of a program

Posted on 1997-03-15
1
213 Views
Last Modified: 2010-04-04
How do i check if theres already a copy of my program running on the system ??
0
Comment
Question by:Daydream
1 Comment
 

Accepted Solution

by:
morwoodk earned 50 total points
ID: 1334766
You need to use the caption of your application to check for other instances of the same.  For this reason it is a good idea to come up with a fairly unique application caption.

To check for other instances of your application use the following:

anAppHandle := FindWindow( nil, 'Your application caption');

anAppHandle is of type HWND and will be nil if there are no other instances loaded.
0

Featured Post

ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

Question has a verified solution.

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

Suggested Solutions

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…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

803 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