Is there anyway to control the sequence of function calls in a excel 开发者_Python百科sheet when it is re-opened ? Excel automatically re-evaluate the functions when it restarts, where I need to ensure one of my function set is called before another set of function calls.
Thank You
I suggest that you create a subroutine named Workbook_Open() It will run when you open the spreadsheet and you can call your subroutines that need to run first there. You obviously can exactly control the order of execution.
Create a fake dependency, so Excel constructs the dependency tree to suit your needs.
For example, if you need A1 to be calculated previously to A2 enter a formula in A2 that is dependent on A1
A2 = Your_Previous_formula() + A1 - A1
So Excel will try to calculate A1 first
I assume that your formulas reference external objects or applications. If there is a REAL inverse dependency currently in your cells you will create circular references.
精彩评论