Public Class Form1 Private Sub ToolStrip1_BeginDrag(ByVal sender As Object, ByVal e As System.EventArgs) Handles ToolStrip1.BeginDrag ToolStripContainer1.LeftToolStripPanel.Hide() ToolStripContainer1.RightToolStripPanel.Hide() End Sub Private Sub ToolStrip1_EndDrag(ByVal sender As Object, ByVal e As System.EventArgs) Handles ToolStrip1.EndDrag ToolStripContainer1.LeftToolStripPanel.Show() ToolStripContainer1.RightToolStripPanel.Show() End Sub End Class
leiqunni 2009/06/28 (Sun) 00:22:08
単純に下記のコードでうまくいくようです。
Public Class Form1
Private Sub ToolStrip1_BeginDrag(ByVal sender As Object, ByVal e As System.EventArgs) Handles ToolStrip1.BeginDrag
ToolStripContainer1.LeftToolStripPanel.Hide()
ToolStripContainer1.RightToolStripPanel.Hide()
End Sub
Private Sub ToolStrip1_EndDrag(ByVal sender As Object, ByVal e As System.EventArgs) Handles ToolStrip1.EndDrag
ToolStripContainer1.LeftToolStripPanel.Show()
ToolStripContainer1.RightToolStripPanel.Show()
End Sub
End Class