向窗体添加控件Add a control to a form

使用以下任意方法从“工具箱”向窗体添加控件。Use any of the following methods to add a control from the Toolbox to your form. 你还可以使用这些方法在窗体上的“”、“TabStrip”或“多页”中插入控件。You can also use these methods to insert a control in a Frame, TabStrip, or MultiPage on the form.

  • 在“工具箱”中单击控件,然后在窗体中单击。Click a control in the Toolbox, and then click in the form. 该控件将以其默认大小出现。The control appears in its default size. 然后您可以拖动控件来更改它的大小。You can then drag the control to change its size.

  • 将工具箱中的控件拖放到该窗体。Drag a control from the Toolbox to the form. 控件显示为默认大小。The control appears in its default size.

  • 在“工具箱”中双击控件,然后在窗体中单击,每个要创建的控件单击一次。Double-click the control in the Toolbox, and then click in the form once for each control that you want to create. 例如,若要创建四个命令按钮,在“工具箱”中双击“CommandButton”,然后在窗体中单击 4 次。For example, to create four command buttons, double-click the CommandButton in the Toolbox and then click four times in the form.

另请参阅See also

支持和反馈Support and feedback

有关于 Office VBA 或本文档的疑问或反馈?Have questions or feedback about Office VBA or this documentation? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.