Code archives/User Libs/System tray icon

This code has been declared by its author to be Public Domain code.

Download source code

System tray icon by Kev
(Posted 23 years ago)
adds support for adding an icon,and menus. allows sending events when your blitz windows dont have focus.(hidden)

an example is included.
homepage.ntlworld.com/pamela.poole/TaskBar.zip

Comments

Agamer
(Posted 23 years ago)
Looks kwl will get it later

Prof
(Posted 23 years ago)
Most impressive Kev. I did actually see another example ages ago but it didn't work on my system. This one works great.

A much needed feature for Blitz Plus so thanks.

Klaas
(Posted 23 years ago)
cool .. needed that badly :-) ... thanks man

Kev
(Posted 23 years ago)
when i get time i was thinking of adding drag&drop feature to blitz windows.

Adren Software
(Posted 23 years ago)
When I downloaded it and ran the exe it wouldn't work. It popped up with an error message. And the bb file had a function missing. Never mind

Kev
(Posted 23 years ago)
it does? its not QueryObject() by any chance.

electronin
(Posted 23 years ago)
Very cool, Kev!
@Blitz Programer - what OS are you running on your computer?

Litobyte
(Posted 23 years ago)
BlitzCC V1.85
(C)opyright 2000-2003 Blitz Research Ltd
Compiling "C:\folder\TaskBarTrayExample.bb"
Parsing...
Generating...
"C:\foler\TaskBarTrayExample.bb"
Line 78 Function 'hidegadget' not found


What Am I missing ?

electronin
(Posted 23 years ago)
HideGadget() is a BlitzPlus function. If you have Blitz3D, then it won't work.

Klaas
(Posted 23 years ago)
when the application is hidden the programm is suspended .. is it possible to catch some timer ticks while hidden ?

The "TaskBarEvent(hWnd,0,0,0,0)" command themes to halt execution of the programm ... any ideas to solve this problem ?

thx

rich d
(Posted 23 years ago)
Yes, it completely halts execution of the program. Is there anyway so that it will still work and recieve events and stuff? Plus, is there anyway to change the icon as to make my own icon? Thanks in advance.

Binary_Moon
(Posted 23 years ago)
I've been playing with this a bit the last couple of days as well :)

The taskBar event pauses everything each time it is called. For now I'm just not using it, and just using the TaksBarMenuEvent since that's all I need. Would be interesting to know why it's so slow though.

Plus, is there anyway to change the icon as to make my own icon?


That one's easy. Create an icon and then specify it in the addTrayIcon command. Mine looks like this

Add_Tray_Icon("Title"+Chr(0),hwnd,"icon.ico")


rich d
(Posted 23 years ago)
How do i create an icon? i know how to add it so it uses it in the program.

Binary_Moon
(Posted 23 years ago)
Use an icon editor - there are loads around but I recommend http://www.snidesoft.com/

rich d
(Posted 23 years ago)
Thx it works great. But has anyone solved the problem of getting events to a program when its in the task bar?

Adren Software
(Posted 23 years ago)
Will it work without the HideGadget()? With Blitz3D?

rich d
(Posted 23 years ago)
I dont know about B3D, but without the hidegadget it will still be visible.

rich d
(Posted 23 years ago)
Has anyone figured out how to give events to the thing while its minimized into the tray?

Kev
(Posted 23 years ago)
Rich05 the .dll only sends events to your program it wont receive all events only standard events, to check what events are received use sys_tray() function. also make sure the tray icon has focus. a rewritten version will go into WinBlitz3D, complete with better event handles.

Adren Software
(Posted 23 years ago)
Is there a version that will work with Blitz3D?

rich d
(Posted 23 years ago)
I doubt it, youll probably have to make it yourself.

B+man
(Posted 23 years ago)
Nice!!!

Dabz

:)

gman
(Posted 22 years ago)
has anyone been successful at changing the popup menu once its been set? if i call DeleteIconMenu() after i have already added menu items, i cant seem to add more and have it function properly. any ideas on what i may be doing wrong?

thank you.

Kev
(Posted 22 years ago)
gman, i havent tryed that. so thanks for pointing it out. i will not be working on this anymore. all my spare time is being used on two projects im coding blitzlockit and winblitz3d.

Arem
(Posted 22 years ago)
Where is it now?

Samuel
(Posted 22 years ago)
http://myweb.tiscali.co.uk/blitzbasic/TaskBar.zip

Sub_Zero
(Posted 21 years ago)
where is it now? :)

Compt-Man
(Posted 20 years ago)
yay where

Code Archives Forum