I’m creating a macro that will select multiple named ranges at one time. I’ve got it to work using “Application.Goto” but only when manually entering the named range title.
I need to make the range more dynamic and allow for user selection of those named ranges. What I’ve done is created a formula in sheet “UPDATES” that uses input from a user dropdown menu selection to return three different named ranges. User selects month to be updated (Jan-Dec), formula in cells A25, A26 and A27 (using CONCATENATE) produces three different named range titles (ranges that are already defined and all on tab “FUNDING(4)”). For example, if the user selects the month "Mar", the three cells below populate with "MarPE", "MarRW", and "MarCN".
How do I force the “Application.Goto” code to use these three cells as the named range titles and simultaneously select the three ranges? Is there a better option available that I'm unaware of? This is to be phase one of what will be a two-phase macro - this phase selects three ranges, then phase two will either copy/paste special those ranges in place or break links. Perhaps there's a better way to do both at once? Thanks All.
Code:
Sub Appl_Goto()
Application.Goto Reference:=Worksheets("Funding(4)").Range("MarPE,MarRW,MarCN"), Scroll:=True
End Sub
I need to make the range more dynamic and allow for user selection of those named ranges. What I’ve done is created a formula in sheet “UPDATES” that uses input from a user dropdown menu selection to return three different named ranges. User selects month to be updated (Jan-Dec), formula in cells A25, A26 and A27 (using CONCATENATE) produces three different named range titles (ranges that are already defined and all on tab “FUNDING(4)”). For example, if the user selects the month "Mar", the three cells below populate with "MarPE", "MarRW", and "MarCN".
How do I force the “Application.Goto” code to use these three cells as the named range titles and simultaneously select the three ranges? Is there a better option available that I'm unaware of? This is to be phase one of what will be a two-phase macro - this phase selects three ranges, then phase two will either copy/paste special those ranges in place or break links. Perhaps there's a better way to do both at once? Thanks All.