Solved

Closing other Apps

Posted on 1997-05-21
2
147 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
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

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
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…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
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.

744 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

13 Experts available now in Live!

Get 1:1 Help Now