Lesson#72: Select an area by clicking a button in Excel with VBA


Here I will show you how to select an area by clicking a button in Excel with VBA.

1. Go to Developer Tab.
2. Click on Insert.
3. Select Button (Form Control).
3. Select Button (Form Control).


4. Put the button on the worksheet by dragging and putting it on the sheet.
5. Immediately Macro name window will appear.6. Click on New.

7. There you have to put this Code.
Sub Button1_Click()
Range(“A1:N20”).Select
End Sub
Range(“A1:N20”).Select
End Sub

8. Click on Run Sub/ UserForm.

Now when you go to the spreadsheet and click on the button A1:N20 area will be selected.
Leave a Reply