?
Solved

Window minimization

Posted on 1998-12-21
8
Medium Priority
?
281 Views
Last Modified: 2010-04-02
I need to redefine function of window minimization.
As i understand, i have to handle a message in my own message-handler function.
Which message can i use (WM_???)
0
Comment
Question by:mcoroli
[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
  • 3
  • 2
  • 2
  • +1
8 Comments
 
LVL 12

Expert Comment

by:migel
ID: 1180764
Hi! May be WM_SHOWWINDOW will help you (when minimasing wParam  is equal SW_MINIMIZE)
0
 
LVL 6

Expert Comment

by:thresher_shark
ID: 1180765
Here is what I would do:
SendMessage (hHandle, WM_SYSCOMMAND, SC_MINIMIZE, 0);

That will minimize the window referred to by hHandle.  Is this what you were looking for?
0
 
LVL 22

Accepted Solution

by:
nietod earned 300 total points
ID: 1180766
What you want to do is to handle the WM_SYSCOMMAND message.  In the message handler check if the wParam is SC_MINIMIZE.  If it is, then do your special processing and return.  If not, then pass the message and parameters to the default window procedure.

Let me know if you have questions.

0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 10

Expert Comment

by:viktornet
ID: 1180767
Hello all!

Here is what I would do if I were you....

To minimize...

ShowWindow(hHandle, SW_MINIMIZE);

To maximize...

ShowWindow(hHandle, SW_MAXIMIZE);

where hHandle is the handle to the window to be minimized or maximized..

Hope this helps!

-Viktor
--Ivanov
0
 
LVL 22

Expert Comment

by:nietod
ID: 1180768
I see thresher_shark hade the same idea.  (EE has been dead for the last 30 minutes, so I ddin't see his rsponse at the time)  Actually, no I think he has it backwards  He is trying to cause minimization, that's not what you want is it?
0
 
LVL 6

Expert Comment

by:thresher_shark
ID: 1180769
Yes I had it backwards.  I have recieved an email from mcoroli.

mcoroli - To post reply on experts-exchange, scroll down to the bottom of the screen where there is a text field.  Enter your comment there and press the submit button.  That is how you respond to people here.
0
 
LVL 22

Expert Comment

by:nietod
ID: 1180770
But, if he isn't scrolling down he isn't going to see that message....  : - )
0
 
LVL 10

Expert Comment

by:viktornet
ID: 1180771
So whose comment(answer) helped u the most to do what you wanted?

Merry Christmas!!!

-Viktor
--Ivanov
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.
Suggested Courses
Course of the Month15 days, 10 hours left to enroll

743 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