On Mon, 12 Jul 2004 22:13:51 -0700, "Michael Geary" <Mike / Geary.com>
wrote:

>To load an icon from a .ico file, use either ExtractIcon or LoadImage.
>ExtractIcon is simpler, but it only looks for one size of icon, the "system
>large" size, typically 32x32 or 48x48. If you want to be able to control
>which size icon you get, use LoadImage instead.
>
>I don't have Ruby code handy to do this, but if you Google for the function
>names above you'll get the MSDN documentation for them.

Thanks, ExtractIcon was what I needed!  Here's the code that works:

ExtractIcon = Win32API.new("shell32","ExtractIcon",['I','P','I'],"I")
FOOICON = ExtractIcon.call(0,"myicon.ico",0)

And then this FOOICON can be used in the create_trayicon function.

Fantastic, I thought it was going to be a lot trickier for some
reason.  Cheers!

-- 
tom / alkali.spamfree.org
remove 'spamfree.' to respond