A couple of additional thoughts:
1)Do you have to wait until period x passes before creating the spreadsheet? I have been known to create the spreadsheet long before it is needed just so I can program the spreadsheet without these kind of errors. The "future" spreadsheets can have something like N/A or "hasn't happened yet" or 0 or some other value in A13 that obviously means that it still is just a placeholder.I am creating a worksheet that needs to input information from other worksheets that have not been created yet.
2) I notice that each conditional test in your formula is for A2=1 or 2 or 3 or 4 or .... For these kind of situations, I tend to make a lookup table and use a lookup function, instead of the long nested IF. That might be worth considering.
Bookmarks