Recent

Author Topic: [CLOSED] How to hide Tray Icon  (Read 5013 times)

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
[CLOSED] How to hide Tray Icon
« on: December 15, 2012, 11:34:29 am »
I am creating a command line application with system tray icon,

myapp -showtray shows the tray application. but when i call mypp -hidetray then the tray is not removed.

 I am using TTrayIcon class.

mytray.show - works. but mytray.hide fails.

I was bit on a wrong track, everything is working fine now. So closing this thread.

Lazarus 1.0.4 (FPC) 2.6.0 on Windows 7(x86)  32bit
« Last Edit: December 16, 2012, 09:50:05 am by deepaak99 »
Holiday season is online now. :-)

eny

  • Hero Member
  • *****
  • Posts: 1665
Re: How to hide Tray Icon
« Reply #1 on: December 15, 2012, 12:40:16 pm »
What happens when you move the mouse over the tray icon?
Windows is not always updating the tray immediately when an icon has disappeared.
When you hover the mouse over the removed icon, it might disappear.
All posts based on: Win11; stable Lazarus 4_4  (x64) 2026-02-12 (unless specified otherwise...)

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: How to hide Tray Icon
« Reply #2 on: December 15, 2012, 01:06:49 pm »
What happens when you move the mouse over the tray icon?

Nothing happens, the icon stays there, with the functions associated with it.

Holiday season is online now. :-)

Deepaak

  • Sr. Member
  • ****
  • Posts: 454
Re: How to hide Tray Icon
« Reply #3 on: December 16, 2012, 05:53:39 am »
please help
Holiday season is online now. :-)

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: How to hide Tray Icon
« Reply #4 on: December 16, 2012, 08:10:04 am »
<sigh> <isn't this obvious???> Upload a compilable sample project that shows the problem if you want somebody to look at it.
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

 

TinyPortal © 2005-2018