对齐控件Align controls

  1. 选择要对齐的控件。Select the controls to align.

  2. 选择“基准控件”。Select the dominant control.

  3. 从“格式”菜单上,选择“对齐”。From the Format menu, choose Align.

  4. 从级联菜单中,选择下列选项之一以将每个选定控件的指定部分与基准控件的相同部分对齐:From the cascading menu, choose one of the following to align the specified part of each selected control with the same part of the dominant control:

    • 左对齐,对齐左边缘。Lefts, to align the left edge.

    • 居中对齐,对齐每个控件的中心。Centers, to align the center of each control. 这意味着在基准控件的中心绘制的竖线将包含每个所选控件的中心。This means a vertical line drawn at the center of the dominant control would contain the center of every selected control.

    • 右对齐,对齐右边缘。Rights, to align the right edge.

    • 顶端对齐,对齐顶端。Tops, to align the top.

    • 中间对齐,对齐每个控件的中心。Middles, to align the center of each control. 这意味着在基准控件的中心绘制的横线将包含每个所选控件的中心。This means a horizontal line drawn at the center of the dominant control would also contain the center of every selected control.

    • 底端对齐,对齐底端。Bottoms, to align the bottom.

    • 与网格对齐,将每个所选控件的左上角与其最近的网格点对齐。To Grid, to align the upper left corner of each selected control with its nearest grid point. 请注意此选项不基于基准控件的位置。Note that this option is not based on the position of the dominant control.

备注

菜单上的每个命令都有一个小图片,显示如何对齐控件。Each command on the menu has a small picture that shows how the controls will be aligned.

另请参阅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.