troubleshooting Question

Catching Windows M..

Avatar of Palamedes
PalamedesFlag for United States of America asked on
18 Comments1 Solution1110 ViewsLast Modified:
I have a program that I don't want users to be able to minimize.

I have set up a SystemCommand routine to catch SC_MINIMIZE which keeps users from clicking the little button.. (also known as SC_ICON)  but it doesn't catch the Windows-M that can also minimize programs.

How do I go about catching that Windows-M..

Here is my current setup:

  procedure SysCommand(var Message: TWMSYSCOMMAND); message WM_SYSCOMAND;

procedure TProgram.SysCommand(var Message: TWMSYSCOMMAND);
  if Message.CmdType and $FFF0 = SC_MINIMIZE then Message.result:=0
  else inherited;

I seem to remember this working for me on my Win98 box.. but now it's not working on my Win2K box..


Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 18 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 18 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros