-
Notifications
You must be signed in to change notification settings - Fork 807
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IXLCell.Value returns incorrect value when using formula that references variable that was not yet added. #1536
Comments
@igitur, this turned out to be trickier than I expected. First, we have to consider named ranges too when analyzing precedent cells. But this is not enough - our |
The issue exists nonetheless
|
NOTE: This same code throws
ClosedXML.Excel.CalcEngine.Exceptions.NameNotRecognizedException: 'The identifier
variableAwas not recognised.'
on build from 'develop' branch. I think this was changed (is that now as designed?) in this commit:f2063a7
Do you want to request a feature or report a bug?
Did you test against the latest CI build?
I used the latest officially released Nuget package v =
0.95.3
If you answered
No
, please test with the latest development build first.Version of ClosedXML
Nuget package v =
0.95.3
What is the current behavior?
In the current released
0.95.3
version we have an issue that if formula has usage of named variable and we access.Value
before this named variable is added to the worksheet and we try to accessformulaCell.Value
after we added named variable toworksheet
we get.Value
incorrectly as old value. ExampleNote that this works fine if I comment out first
formulaCell.Value
access:What is the expected behavior or new feature?
formulaCell.Value
is correctly invalidated and results to25
at the last line.Is this a regression from the previous version?
No
Reproducibility
Code to reproduce problem:
cc: @igitur
The text was updated successfully, but these errors were encountered: