Solved

Closing other Apps

Posted on 1997-05-21
2
169 Views
Last Modified: 2012-05-04
My password program is called from a macro in a help file. If the user types in the wrong password, then the help file has to be closed. I know that this has can be done with messages, but how?
0
Comment
Question by:richweed
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 1

Accepted Solution

by:
sleach earned 50 total points
ID: 1336507
Substitute the  ClassName & caption of the app you want to close into the code below.  If your not sure what they are, use Winsight(included with Delphi).  If you already have the handle to the window, just use it instead of FindWindow.

   PostMessage(FindWindow('ClassName', 'caption'),
   WM_QUIT, 0, 0);

0
 

Author Comment

by:richweed
ID: 1336508
What about closing all windows?
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

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.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Delphi component that can load a DLL in design time? 8 107
Delphi IDE crash without error message ... 7 141
SUM 2 INTEGER ARRAYS INTO 1 10 118
Browsing a TTreeView in Delphi 5 49
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…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

752 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