Solved

taskbar

Posted on 1998-09-24
3
328 Views
Last Modified: 2010-04-30
how can i create a taskbar in a vb form?
0
Comment
Question by:rutexavier
3 Comments
 

Expert Comment

by:tenaka
Comment Utility
How can I put a toolbar in my application?

               Compatibility:VB3  VB4  VB5

I pulled this of the Cool VB site, don't know if it's what you're after.

t

               Create a new form with all your buttons on it. Under VB5, you'll want to set the border property to "4 - ToolWindow".

               Put the following declarations in a new module:

               declare Function SetWindowWord Lib "User32" (ByVal hWnd as Long, ByVal _
                nIndex as long,  ByVal nNewWord as long) as long

               Next, put the following code in the load event of the toolbar form.

               SetWindowWord Me.hWnd, -8, Main.hWnd

               Replace main with the name of your main form.

0
 
LVL 3

Expert Comment

by:rmichels
Comment Utility
By Task Bar, do you mean like MS-OFFICE or the Win 95 Taskbar?  There is much more to doing this then just setting the form as a toolbar.  There are an entire series of window messages/apis that deal with managing a Task Bar. For example,  As a Task Bar you tell windows who you are and your size and Windows adjusts the workspace on the desktop so that forms maximize properly.  I found some C code on the Microsoft site that does this and was converting it to VB, but I never finished it.
0
 
LVL 3

Accepted Solution

by:
HATCHET earned 0 total points
Comment Utility
rutexavier,

To create a TOOLBAR in your VB form, right click on the ToolBox window and select "Components...".  Select the Microsoft Common Controls (SP2) - COMCTL32.OCX.  Click OK.  Double Click on the Toolbar Control to place it on your form and set the properties according to how you want it to look.  Right click on the newly placed Toolbar and select Properties for more options on how you can configure it.

To create a TASKBAR, as in a Toolbar similar to the types that IE 4.0x and Office 97 use, go to the following web site and read up on it.  There's a control you can download and use that does most the work for you.  I've used it before and really like it :

Office 97 Toolbar :
http://www.zonecorp.com/VB5/Toolbar.htm

IE 4 Toolbar :
http://www.zonecorp.com/VB5/RebarVB.htm

Microsoft Support Document on creating custom Toolbars :
http://support.microsoft.com/support/kb/articles/q142/1/87.asp

Good luck,

HATCHET
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now