本文整理了Java中org.apache.poi.hssf.usermodel.HSSFSheet.updateFormulasForShift()
方法的一些代码示例,展示了HSSFSheet.updateFormulasForShift()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。HSSFSheet.updateFormulasForShift()
方法的具体详情如下:
包路径:org.apache.poi.hssf.usermodel.HSSFSheet
类名称:HSSFSheet
方法名:updateFormulasForShift
暂无
代码示例来源:origin: org.apache.poi/poi
/**
* Shifts columns in range [startColumn, endColumn] for n places to the right.
* For n < 0, it will shift columns left.
* Additionally adjusts formulas.
* Probably should also process other features (hyperlinks, comments...) in the way analog to shiftRows method
* @param startRow the row to start shifting
* @param endRow the row to end shifting
* @param n the number of rows to shift
*/
@Beta
@Override
public void shiftColumns(int startColumn, int endColumn, int n){
HSSFColumnShifter columnShifter = new HSSFColumnShifter(this);
columnShifter.shiftColumns(startColumn, endColumn, n);
int sheetIndex = _workbook.getSheetIndex(this);
short externSheetIndex = _book.checkExternSheet(sheetIndex);
String sheetName = _workbook.getSheetName(sheetIndex);
FormulaShifter formulaShifter = FormulaShifter.createForColumnShift(
externSheetIndex, sheetName, startColumn, endColumn, n, SpreadsheetVersion.EXCEL97);
updateFormulasForShift(formulaShifter);
// add logic for hyperlinks etc, like in shiftRows()
}
代码示例来源:origin: org.apache.poi/poi
externSheetIndex, sheetName, startRow, endRow, n, SpreadsheetVersion.EXCEL97);
updateFormulasForShift(formulaShifter);
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi
/**
* Shifts columns in range [startColumn, endColumn] for n places to the right.
* For n < 0, it will shift columns left.
* Additionally adjusts formulas.
* Probably should also process other features (hyperlinks, comments...) in the way analog to shiftRows method
* @param startRow the row to start shifting
* @param endRow the row to end shifting
* @param n the number of rows to shift
*/
@Beta
@Override
public void shiftColumns(int startColumn, int endColumn, int n){
HSSFColumnShifter columnShifter = new HSSFColumnShifter(this);
columnShifter.shiftColumns(startColumn, endColumn, n);
int sheetIndex = _workbook.getSheetIndex(this);
short externSheetIndex = _book.checkExternSheet(sheetIndex);
String sheetName = _workbook.getSheetName(sheetIndex);
FormulaShifter formulaShifter = FormulaShifter.createForColumnShift(
externSheetIndex, sheetName, startColumn, endColumn, n, SpreadsheetVersion.EXCEL97);
updateFormulasForShift(formulaShifter);
// add logic for hyperlinks etc, like in shiftRows()
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi
externSheetIndex, sheetName, startRow, endRow, n, SpreadsheetVersion.EXCEL97);
updateFormulasForShift(formulaShifter);
内容来源于网络,如有侵权,请联系作者删除!