Adding a footer to dynamic sheet list

kmakino

New Member
Joined
Jul 29, 2021
Messages
1
Platform
  1. Windows
So I'm trying to get footers attached to a dynamic sheet list.

On a tab, I have the sheet names in cells that I want to attach footer as a named range (called Sheet_List) such as:
A1: Page_1
A2: Page_2
etc.

In VBA, I was wondering if I can refer to the named range "Sheet_List" to attach footers instead of typing in the sheet names in the code. Right now, I have

For Each ws In Array(Sheets("Page_1"), Sheets("Page_2"))
ws.PageSetup.LeftFooter = "Stuff"
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK

Forum statistics

Threads
1,147,497
Messages
5,741,499
Members
423,662
Latest member
Ajmal Khursand

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top