QP School

Full Version: Worksheet methods in VBA
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Description:

Worksheets are objects in Excel, and they have methods like Activate, Select, and Copy.

Example:

Sub ExampleWorksheetMethods()
    'Activate a specific worksheet
    Worksheets("Sheet1").Activate

    'Select a range on the active worksheet
    Range("A1").Select

    'Copy the entire worksheet
    Worksheets("Sheet1").Copy
End Sub