I've found a few tutorials that explain how to use the windows API to get a custom icon in the system tray.
These are all for Visual Basic, and they don't seem to be scaling to VBA well.
I'm following this short tutorial: http://atchoo.org/vb/systray.php
Basically, you have to set the hIcon value (a 'long' variable) but it does not work. I've tried to use the LoadPicture() function, which does not give me any errors, but also fails to add a new icon.
I can't supply Me.Icon, nor can I set it on Form_Load.
Does anyone have any experience with this?
Using loadpicture was the right approach, but not directly. I had to define a new variable first, and load that.
Like this:
And then, somewhere along the way, I could set hIcon without problems:
When I change the trayicon (like, say, adding a balloontip) I have to supply the icon information again, too.