Author: fanningpj
Date: Fri Apr 29 13:07:00 2022
New Revision: 1900383
URL: http://svn.apache.org/viewvc?rev=1900383&view=rev
Log:
[bug-66039] add more javadoc about setCellFormulaValidation
Modified:
poi/trunk/poi-ooxml/src/main/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java
poi/trunk/poi/src/main/java/org/apache/poi/ss/usermodel/Cell.java
Modified:
poi/trunk/poi-ooxml/src/main/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java
URL:
http://svn.apache.org/viewvc/poi/trunk/poi-ooxml/src/main/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java?rev=1900383&r1=1900382&r2=1900383&view=diff
==============================================================================
---
poi/trunk/poi-ooxml/src/main/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java
(original)
+++
poi/trunk/poi-ooxml/src/main/java/org/apache/poi/xssf/usermodel/XSSFWorkbook.java
Fri Apr 29 13:07:00 2022
@@ -2485,6 +2485,7 @@ public class XSSFWorkbook extends POIXML
/**
* Whether a call to {@link XSSFCell#setCellFormula(String)} will validate
the formula or not.
+ * When enabled (which is the default), this option can lead to formulas
being modified by POI formula renderer.
*
* @param value true if the application will validate the formula is
correct
* @since 3.17
@@ -2495,6 +2496,7 @@ public class XSSFWorkbook extends POIXML
/**
* Whether a call to {@link XSSFCell#setCellFormula(String)} will validate
the formula or not.
+ * When enabled (which is the default), this option can lead to formulas
being modified by POI formula renderer.
*
* @since 3.17
*/
Modified: poi/trunk/poi/src/main/java/org/apache/poi/ss/usermodel/Cell.java
URL:
http://svn.apache.org/viewvc/poi/trunk/poi/src/main/java/org/apache/poi/ss/usermodel/Cell.java?rev=1900383&r1=1900382&r2=1900383&view=diff
==============================================================================
--- poi/trunk/poi/src/main/java/org/apache/poi/ss/usermodel/Cell.java (original)
+++ poi/trunk/poi/src/main/java/org/apache/poi/ss/usermodel/Cell.java Fri Apr
29 13:07:00 2022
@@ -232,10 +232,14 @@ public interface Cell {
*
* <p>If the cell was blank, sets value to 0. Otherwise, preserves the
value as precalculated.</p>
*
+ * <p></p>In XSSF implementation, there is a
<code>XSSFWorkbook.setCellFormulaValidation(boolean)</code>
+ * setting that can validate (but also in some cases, reformat) the
formula.</p>
+ *
* @param formula the formula to set, e.g. <code>"SUM(C4:E4)"</code>.
* If the argument is <code>null</code> then the current formula is
removed.
*
* @see Cell#removeFormula
+ * @see Workbook#setForceFormulaRecalculation(boolean)
* @throws IllegalStateException if this cell is a part of an array
formula group containing other cells
* @throws FormulaParseException if the formula has incorrect syntax or is
otherwise invalid
*/
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]