I have four variables as follows: theta_1, theta_2, alpha_1, and alpha_2. Based on these variables (which are already calculated), I need to pull data from the four worksheets that corresponds. Each sheet is named for t[insert number]a[insert number], since theta and alpha both contribute to the output.
This is tough to describe, so I think it may be best to give an example:
Let say theta_1 = 30, theta_2 = 35, alpha_1 = 10, and alpha_2 = 15.
I would need to retrieve the following four worksheets: t30a10, t30a15, t35a10, and t35a15.
In VBA, is there a way to (for lack of a better word) "select" these worksheets without having to do a very long if/then statement for each case? I don't need to "select" the worksheets, I just need the code to know that it needs to be referring to only those four sheets (out of roughly 100 sheets total).
Thanks.
Bookmarks