Create your Own TaskBar Control in VB5/6

I coded this within a couple hours tonight (7/11/1999). It works well for its limited design goals, but it needs some features expanded.

screen-shot

Source code is included.

Properties

HangDown

The number of pixels that will hang down into the screen when the taskbar is hidden.

NumSteps

The number of steps drawn while moving the taskbar down.

Events

AppGotFocus

Similar to Form.GotFocus, but also works when the application gets the focus.

AppLostFocus

Similar to Form.LostFocus, but also works when the application loses focus.

MouseOver

The mouse was moved over the taskbar.

MouseLeft

The mouse left the taskbar window.

StartOpenUp

The taskbar started to open up.

StartCloseUp

The taskbar started to close up.

ChangeOpenUp

The taskbar was closing, but started to open.

ChangeCloseUp

The taskbar was opening, but started to close.

EndOpenUp

The taskbar is open all the way.

EndCloseUp

The taskbar is closed all the way.

Source Code

The control is distributed via source code. The license is GPL. (see www.gnu.org/copyleft/gpl.html) If you make any significant changes, please let me know and I'll distribute them with this. Or if you're just using it for something amazingly cool, I'd be interested to know about that too.

Limitations/Problems

  • Taskbar can only be placed at the center top of the screen.
  • "Runs" while in the IDE.
  • Opening and closing are somewhat slow (especially compared to start menu).
  • The whole thing has too many hacks involving timers.

Author

Any suggestions, helpful hints, or flames should be directed to:

David Newcum
newcumdb@cs.purdue.edu
http://www.cs.purdue.edu/homes/newcumdb/

Download Zipped Project File (13k)



Comments

  • taskbar

    Posted by Legacy on 01/06/2001 12:00am

    Originally posted by: vishal

    your program is not able to adjust the screen acordind to bar as happens in caltiger.com

    Reply
  • Fix for the timers in the taskbar project

    Posted by Legacy on 05/14/2000 12:00am

    Originally posted by: John Meller

    For those of you who dont know how to fix the 'timer' problem in this taskbar project here is the fix
    Private Sub UserControl_InitProperties()
    'this will disable the time when you are in design mode
    Timer1.Enabled = Ambient.UserMode
    End Sub

    Private Sub UserControl_ReadProperties(PropBag As PropertyBag)
    'this will disable the time when you are in design mode
    Timer1.Enabled = Ambient.UserMode
    End Sub

    Hope this helps :)

    Reply
Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • Java developers know that testing code changes can be a huge pain, and waiting for an application to redeploy after a code fix can take an eternity. Wouldn't it be great if you could see your code changes immediately, fine-tune, debug, explore and deploy code without waiting for ages? In this white paper, find out how that's possible with a Java plugin that drastically changes the way you develop, test and run Java applications. Discover the advantages of this plugin, and the changes you can expect to see …

  • Agile development principles have gone from something used only by cutting-edge teams to a mainstream approach used by teams large and small. If you're not using agile methods already though, or if you've only been exposed to agile on small projects here and there, you may wonder if agile can ever work in your environment. Read this eBook to learn the fundamentals of agile and how to increase the productivity of your software teams while enabling them to produce higher-quality solutions that better fulfill …

Most Popular Programming Stories

More for Developers

Latest Developer Headlines

RSS Feeds