Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

How to create system tray dialog box?

I made program to talk over LAN, it works fine but I want it to work in the system tray, the main window is dialog box. I'm using LCC 32

thanks


Comments

  • I've never used LCC 32, but the API to use is Shell_NotifyIcon, the MSDN help on the function is 5 lines or so :) But there's a VB sample you can look at, its straight forward.



    If I were you I'd create my dialog as usual but make it invisible, when the user double clicks the icon, I show the dialog, when minimized hide it again and finally when closed I'd remove the icon and terminate.



    A pop up menu when right clicking the icon is also a standard thing, just dont forget to call SetForegroundWindow(hDialog) before you call TrackPopupMenu.



    : I made program to talk over LAN, it works fine but I want it to work in the system tray, the main window is dialog box. I'm using LCC 32

    : thanks

    :






Sign In or Register to comment.