In this exercise, you learn about the Format menus Align, Make Same Size, and Center in Form

Question:

In this exercise, you learn about the Format menu’s Align, Make Same Size, and Center in Form options.

a. Open the VB2015\Chap01\Format Solution\Format Solution (Format Solution.sln) file. If necessary, open the designer window.

b. Click the Button2 control, and then press and hold down the Ctrl (Control) key as you click the other two button controls. Release the Ctrl key. Notice that the sizing handles on the first button you selected (Button2) are white, while the sizing handles on the other two buttons are black. The Align and Make Same Size options on the Format menu use the control with the white sizing handles as the reference control when aligning and sizing the selected controls. First, you will practice with the Align option by aligning the three buttons by their left borders. Click Format, point to Align, and then click Lefts. The left borders of the Button1 and Button3 controls are
aligned with the left border of the Button2 control, which is the reference control.

c. The Make Same Size option makes the selected objects the same height or width, or both. Here again, the first object you select determines the size. Click the form to deselect the three buttons. Click Button1, Ctrl+click Button2, and then Ctrl+click Button3. Click Format, point to Make Same Size, and then click Both. The height and width of the Button2 and Button3 controls now match the height and width of the reference control (Button1).

d. Click Format, point to Center in Form, and then click Horizontally to center the controls horizontally on the form.

e. Click the form to deselect the buttons. Save and then close the solution.

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: