473,378 Members | 1,409 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Moveable toolbar

How do I create a moveable toolbar that can be docked on a windows form?.
I'm using vb .net (2002).

I have added the toolbar item to the windows form, but I cannot see a way of
making it draggable, nor adding the classic 'dragging bar' on the left hand
side of the toolbar?

(sorry, I'm a new to VB .net)

Flashster

Nov 21 '05 #1
3 3179
Flashter,

Why you take difficult parts first when you are new to VBNet. As most answer
on this that they have a lot of experience in other language. Than I can
give you the answers direct. Try first the usual things, than the answer on
this kind of problems will come automatically.

Although that there are thirth party controls, by instance at syncfusion

http://www.syncfusion.com/Products/Studio.aspx

If it is just replacing it on your form look than add the dock property of
the toolbar

I hope this helps,

Cor
Nov 21 '05 #2
I should have said that although I am not that familiar with VB .net, I am
familiar with programming generally.

I know of third part solutions to do this - but is there any examples of how
to have a floating toolbar in a windows form in VB .net?

As far as I can see the 'dock' property allows you to fix the bar in a
position within the form, but how do you allow the user to actually drag the
toolbar to where they want?

"Cor Ligthert [MVP]" <no************@planet.nl> wrote in message
news:eW**************@TK2MSFTNGP09.phx.gbl...
Flashter,

Why you take difficult parts first when you are new to VBNet. As most
answer on this that they have a lot of experience in other language. Than
I can give you the answers direct. Try first the usual things, than the
answer on this kind of problems will come automatically.

Although that there are thirth party controls, by instance at syncfusion

http://www.syncfusion.com/Products/Studio.aspx

If it is just replacing it on your form look than add the dock property of
the toolbar

I hope this helps,

Cor

Nov 21 '05 #3
Hi,

set the toolbars dock property to false and try this code:

Private dragging As Boolean
Private beginX, beginY As Integer

Private Sub ToolBar1_MouseDown(ByVal sender As Object, ByVal e As _
System.Windows.Forms.MouseEventArgs) Handles ToolBar1.MouseDown

dragging = True
beginX = e.X
beginY = e.Y

End Sub

Private Sub ToolBar1_MouseMove(ByVal sender As Object, ByVal e As _
System.Windows.Forms.MouseEventArgs) Handles ToolBar1.MouseMove
If dragging = True Then
ToolBar1.Location = New Point(ToolBar1.Location.X + e.X -
beginX, ToolBar1.Location.Y + e.Y - beginY)
Me.Refresh()
End If
End Sub

Private Sub ToolBar1_MouseUp(ByVal sender As Object, ByVal e As _
System.Windows.Forms.MouseEventArgs) Handles ToolBar1.MouseUp

dragging = False

End Sub

hth Greetz Peter

--
Programming today is a race between software engineers striving to build
bigger and better idiot-proof programs, and the Universe trying to produce
bigger and better idiots. So far, the Universe is winning.

"Flashster" <fl***********@hotmail.com> schreef in bericht
news:uR*************@TK2MSFTNGP09.phx.gbl...
I should have said that although I am not that familiar with VB .net, I am
familiar with programming generally.

I know of third part solutions to do this - but is there any examples of how to have a floating toolbar in a windows form in VB .net?

As far as I can see the 'dock' property allows you to fix the bar in a
position within the form, but how do you allow the user to actually drag the toolbar to where they want?

"Cor Ligthert [MVP]" <no************@planet.nl> wrote in message
news:eW**************@TK2MSFTNGP09.phx.gbl...
Flashter,

Why you take difficult parts first when you are new to VBNet. As most
answer on this that they have a lot of experience in other language. Than I can give you the answers direct. Try first the usual things, than the
answer on this kind of problems will come automatically.

Although that there are thirth party controls, by instance at syncfusion

http://www.syncfusion.com/Products/Studio.aspx

If it is just replacing it on your form look than add the dock property of the toolbar

I hope this helps,

Cor


Nov 21 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

102
by: me | last post by:
How do I prevent the save/print/email/mypictures toolbar from popping up when IE users place their cursor over photos at my website? Thank you in advance for your help. Signed, me
2
by: Galaxia | last post by:
Hi, I'm using C# in VS .Net 2003. How can I build movable toolbars as that in VS IDE, dragging and arranging them? More, how can the moveable toolbar be put into the same line of Menu, as that in...
1
by: simon | last post by:
Is it posible to create moveable panel in asp.net? When user clicks on time link in my dataGrid, I open the panel over the datagrid. If the panel is opened, than data below the panel is not...
3
by: VJ | last post by:
I am looking to implement moveable toolbars like in Word, or Visual Studio... any pointers or articles would great.. Thanks VJ
6
by: Juan Pedro Gonzalez | last post by:
I wanted to add a Combobox to a toolbar... Kind of the look you get on VisualStudio's toolbar. I've been able to find some VB 6 samples, but the placeholder option is no longer available for...
1
by: Alfredo Barrientos | last post by:
Hi, I have a little trouble trying to assign a Toolbar control to another toolbar variable control. I am getting my forms controls with this: for (int j = 0; j <= frmChild.Controls.Count -...
6
by: ll | last post by:
Hi, I'm currently working with a 'classic ASP' intranet site which uses a SQL server and am looking for possible ways to market it as an application for certain medical fields. Where would be a...
6
by: =?Utf-8?B?L2Rldi9udWxs?= | last post by:
Hello, i am using visual studio 2003 enterprise architect version. I am making apps for the .Net framework 1.1. While testing an interface, i discovered something strange. In this application...
4
by: olseni | last post by:
Hi, i am trying to make a report which consists of many subreports, and I need to make the subreports moveable and not show when the subreport has no data. I use an event procedure in the 'On no...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.