Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dockable form 1

Status
Not open for further replies.

Pampers

Technical User
Apr 7, 2004
1,300
0
0
AN
Hi everyone,
I made a one form app in VS2005 (VB.NET). How can I make the form a dockable form so the user can dock somewhere in the screen...

Pampers [afro]
Keeping it simple can be complicated
 
Public Class Form1
Private Sub Form1_LocationChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.LocationChanged
If Me.Left < Screen.PrimaryScreen.Bounds.Width / 2 Then
Me.Left = 0
Else
Me.Left = Screen.PrimaryScreen.Bounds.Width - Me.Width
End If
End Sub
End Class
 
Hi Drederick,
It's firmly glued to the left or right side of the screen! Nice. But not exactly what I was looking for. Maybe I should used the word auto hide, like vs2005 menu's (toolbox, properties etc.) itself, who foldup to the left or right if they don't have focus. If you mouse over, they fold out again.

Pampers [afro]
Keeping it simple can be complicated
 
tnx Tipgiver,
DockPanel looks very nice and the thing i'm looking for. Now I just have to get it to work...


Pampers [afro]
Keeping it simple can be complicated
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top