我需要在左侧创建工具条。但工具箱没有任何 ToolStripContainer。
因此,我尝试通过在设计文件中编码来手动添加 ToolStripContainer。但是 ToolStripContainer 是由红十字绘制的。
Private Sub InitializeComponent()
Me.toolStripContainer1 = New System.Windows.Forms.ToolStripContainer()
Me.SuspendLayout()
Me.toolStripContainer1.Size = New System.Drawing.Size(635, 407)
Me.toolStripContainer1.TabIndex = 0
Me.toolStripContainer1.Text = "ToolStripContainer1"
Me.Controls.Add(Me.toolStripContainer1)
Me.toolStripContainer1.LeftToolStripPanel.ResumeLayout(False)
Me.toolStripContainer1.LeftToolStripPanel.PerformLayout()
Me.ResumeLayout(False)
Me.PerformLayout()
End Sub
我可以在 .Net 5.0 中使用 ToolStripContainer