How to “shift cell right” from the selected cell in Java Aspose Cell.
Thanks for your query.
You may please give a try to the following sample code and provide the feedback.
Workbook workbook = new Workbook(path + "bkRange.xlsx"); Worksheet worksheet = workbook.getWorksheets().get(0); CellArea area = CellArea.createCellArea(1,1,5,5); worksheet.getCells().insertRange(area, ShiftType.RIGHT); workbook.save(path + "outputJava.xlsx");
thanks for helping us, but i am facing another issue there are left border automatic enable from the same Shifted CellArea. can we remove it from the Selected Cell Area.
Please share screenshots describing it, and your sample files (source and output file) with us for our testing. We will reproduce the problem and provide our feedback after analysis.
Hey thanks for feedback, I have resolved the issue. Can you please say about if I shift the cell the particular farmula will be shift or not.
Good to know that you have sorted out your issue now. Also, formulas would be adjusted accordingly when you insert a range of cells similar to what MS Excel does. If you find any issue (regarding shifting formulas), kindly do provide us template files (input and output file) and sample code (runnable) to reproduce the issue, we will check it soon.