Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. Visual Basic
  4. Don't allow notifyIcon to be hidden

Don't allow notifyIcon to be hidden

Scheduled Pinned Locked Moved Visual Basic
comjsonquestion
9 Posts 5 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    LCARS x32
    wrote on last edited by
    #1

    Is there some way to stop Windows from hiding a notifyIcon? I'm not afraid of API calls if they're necessary. We're developing a program that will minimize to the tray and it's important that it's icon is always visible (it updates the user by changing the icon as events occur). I'm sure there's a way, since the Windows icons do it. Thanks, Ray Phillips Jeff Computers StudyX.com

    L 1 Reply Last reply
    0
    • L LCARS x32

      Is there some way to stop Windows from hiding a notifyIcon? I'm not afraid of API calls if they're necessary. We're developing a program that will minimize to the tray and it's important that it's icon is always visible (it updates the user by changing the icon as events occur). I'm sure there's a way, since the Windows icons do it. Thanks, Ray Phillips Jeff Computers StudyX.com

      L Offline
      L Offline
      Luc Pattyn
      wrote on last edited by
      #2

      NotifyIcons do what you tell them to do, they don't just disappear. In fact you have to add extra code (a call to Dispose) to make sure they disappear when your app exits. If your NI disappears inadvertently it tells me it is being garbage collected, which implies you didn't give it enough scope. Is it a member of your form class? It should not be a local variable! :)

      Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum

      Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

      L 1 Reply Last reply
      0
      • L Luc Pattyn

        NotifyIcons do what you tell them to do, they don't just disappear. In fact you have to add extra code (a call to Dispose) to make sure they disappear when your app exits. If your NI disappears inadvertently it tells me it is being garbage collected, which implies you didn't give it enough scope. Is it a member of your form class? It should not be a local variable! :)

        Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum

        Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

        L Offline
        L Offline
        LCARS x32
        wrote on last edited by
        #3

        What I meant was, if the user has auto hiding of their notify icons turned on, the icon gets "hidden" (where you have to push the arrow to see the "hidden" icons). We need ours to always be visible. It's not that the icon is disappearing, per se; it's being hidden until the user clicks that arrow. Sorry for the confusion :) -Ray Jeff Computers StudyX.com

        L 1 Reply Last reply
        0
        • L LCARS x32

          What I meant was, if the user has auto hiding of their notify icons turned on, the icon gets "hidden" (where you have to push the arrow to see the "hidden" icons). We need ours to always be visible. It's not that the icon is disappearing, per se; it's being hidden until the user clicks that arrow. Sorry for the confusion :) -Ray Jeff Computers StudyX.com

          L Offline
          L Offline
          Luc Pattyn
          wrote on last edited by
          #4

          You must be using Windows 7 then. I expect the official stance will be: the behavior of NotifyIcons is a user's choice, and should not be set by the app; the user can: - have inactive icons hidden (the default?); - have all icons show; - choose for each individual icon (the choice persists, seems associated with the EXE file, not the process). I am unaware of any code that would allow an app to change its own NotifyIcon behavior. However, there is this article that may interest you: WPF NotifyIcon[^]. PS: the Windows icons that always show are "system icons", they are handled differently; I don't expect the NotifyIcon class maps to them at all. :)

          Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum

          Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

          S 1 Reply Last reply
          0
          • L Luc Pattyn

            You must be using Windows 7 then. I expect the official stance will be: the behavior of NotifyIcons is a user's choice, and should not be set by the app; the user can: - have inactive icons hidden (the default?); - have all icons show; - choose for each individual icon (the choice persists, seems associated with the EXE file, not the process). I am unaware of any code that would allow an app to change its own NotifyIcon behavior. However, there is this article that may interest you: WPF NotifyIcon[^]. PS: the Windows icons that always show are "system icons", they are handled differently; I don't expect the NotifyIcon class maps to them at all. :)

            Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum

            Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

            S Offline
            S Offline
            Steve Maier
            wrote on last edited by
            #5

            XP allows the notify icons to be hidden as well. There is a setting in XP to allow you to change an icon to be always hide, or always show. So even if you were to programmatically change it, you might have to try to detect if the user changed it manually and to change it back.

            Steve Maier

            L 1 Reply Last reply
            0
            • S Steve Maier

              XP allows the notify icons to be hidden as well. There is a setting in XP to allow you to change an icon to be always hide, or always show. So even if you were to programmatically change it, you might have to try to detect if the user changed it manually and to change it back.

              Steve Maier

              L Offline
              L Offline
              LCARS x32
              wrote on last edited by
              #6

              Ho hum... that's what I was afraid of. lol. Thanks for the replies. Looks like I'll have to find a "creative solution". The Code Project and it's community ROCKS! :cool: -Ray Jeff Computers StudyX.com

              D L 3 Replies Last reply
              0
              • L LCARS x32

                Ho hum... that's what I was afraid of. lol. Thanks for the replies. Looks like I'll have to find a "creative solution". The Code Project and it's community ROCKS! :cool: -Ray Jeff Computers StudyX.com

                D Offline
                D Offline
                dandy72
                wrote on last edited by
                #7

                Raymond Chen would call your app the most awesome program in the history of the universe[^]. And I think he's got a point. Let the user decide--it is user-configurable.

                1 Reply Last reply
                0
                • L LCARS x32

                  Ho hum... that's what I was afraid of. lol. Thanks for the replies. Looks like I'll have to find a "creative solution". The Code Project and it's community ROCKS! :cool: -Ray Jeff Computers StudyX.com

                  L Offline
                  L Offline
                  Lost User
                  wrote on last edited by
                  #8

                  LCARS x32 wrote:

                  Looks like I'll have to find a "creative solution".

                  Most users would prefer that you didn't. Let the user decide whether he wants the icon hidden or not. It is not for applications (and their designers) to tell users how their desktop should be managed.

                  I must get a clever new signature for 2011.

                  1 Reply Last reply
                  0
                  • L LCARS x32

                    Ho hum... that's what I was afraid of. lol. Thanks for the replies. Looks like I'll have to find a "creative solution". The Code Project and it's community ROCKS! :cool: -Ray Jeff Computers StudyX.com

                    L Offline
                    L Offline
                    Lost User
                    wrote on last edited by
                    #9

                    How about a deskband? :)

                    I are Troll :suss:

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups