Statements (that include reference to i) Next Working with Worksheets The worksheets of a workbook are contained in the Any member can be Worksheets collection. specified with its name: Ex: Worksheets(“WSU”) The preceding example applies to the active To access a sheet from a different workbook. (open) workbook: Ex: Workbooks(“Cougs.xlsm”).Worksheets(“WSU”) Counting To the number of worksheets: Ex: Worksheets.Count Adding a Worksheet To create a new worksheet in the workbook: Ex: Worksheets.Add ActiveSheet.Name = “CougsRule” Having a Button Send User to a Specific Sub GoToLists()
Statements (that include reference to i) Next Working with Worksheets The worksheets of a workbook are contained in the Worksheets collection. Any member can be specified with its name: Ex: Worksheets(“WSU”) The preceding example applies to the active workbook. To access a sheet from a different (open) workbook: Ex: Workbooks(“Cougs.xlsm”).Worksheets(“WSU”) Counting To the number of worksheets: Ex: Worksheets.Count Adding a Worksheet To create a new worksheet in the workbook: Ex: Worksheets.Add ActiveSheet.Name = “CougsRule” Having a Button Send User to a Specific Sub GoToLists()
MgtOp-470-Topic-3-Set-3.docx