You are here:

C++/Minimize to system tray



Yeah so it will sit by the clock in the taskbar and wont take up a space next to all the open applications. Im not very good at explaining this sorry.

Like msn messenger for example, when u close it it shrinks to by the clock

Thank you for your fast reply

Anythign else u need to know feel free to ask

Thanks again

Followup To
Question -
Hi There,

I have been learnign C++ for sometime now and my latest application requires me to minimize the application to the system tray.

I am using Borland C++ and have tried to googling it and have been unsucessful so far.

Anyhelp you can give would be great

Many thanks


Answer -
Hello Gareth, thank you for the question.

Just to make sure I understand everything correctly, you have a windowed Windows application and you want to implement the minimizing and maximizing of the application window to the taskbar. Is this correct?

- Eddie

Hello Gareth, thank you for the question.

In your WndProc function, you can set up to catch you WM_SIZE event. This is sent when the window is resized. There you can use your wparam and lparam variables passed into the function. These represent the window width and height. If you do not do anything special, you can use this as the default to your swithc statement and it should handle everything accordingly:

 return DefWindowProc(hWnd, message, wParam, lParam);

I hope this information was helpful.

- Eddie


All Answers

Answers by Expert:

Ask Experts




I can answer questions about the C++ language, object oriented design and architecture. I am knowledgable in a lot of the math that goes into programming, and am certified by I also know a good deal about graphics via OpenGL, and GUIs.


I have completed numerous games and demos created with the C++ programming language. Currently employed as a software engineer in the modeling and simulation field. I have about 7 years experience.

©2017 All rights reserved.