I am wondering if it's possible to move whole column in PHPExcel
.
The case:
I have xlsx file which needs to be validated (per row). Invalid cells need to be marked, comments should be added and so on. I want to add column which would indicate if row is valid or not (any of invalid cell = invalid row) and will group all comments into one for better readability.
I want that additional column at the beginning, but it would change other columns' indexes and I don't want it before validation since I have columns' map for validation logic. I think it could be done with inserting new column at the end and moving it to the beginning after validation process.
BUT
I don't see any method for moving column, only for inserting.
Optional solutions
- inserting at the end, second at the beginning, then copy&paste and removing last column? is copy&pasting whole columns possible?
- make helper methods for manipulating data with addressing cells with +1 index after column insert?
Any ideas how it should be done with minimal effort?