Hi, I have looked for a solution to this and am unable to find one. I have a series of tab with a number code and month such as "12345 - April", and for subsequent months it will be "12345 - May" with the month changing each time for each of the number code tabs. I am referencing to the tabs directly in cells in my workbook using indirect formulas where I have constructed the tab name. How can I select and edit these tabs in VBA, so I can then make changes on that tab? I have tried the following but it is obviously not working. The date is in the "Report_Date range on the Inputs tab with the date from which the month that is in the tab name is pulled.
Thank you for your help!
Thank you for your help!
VBA Code:
Sub Tab_Selection()
Dim sheet_name As String
Sheets("Inputs").Select
sheet_name = "12345 - " & ActiveSheet.Range(Format("Report_Date", "MMMMM").Value
Sheets(sheet_name).Select
End Sub