多列上的PHPExcel removeColumn不能用作Excel删除

时间:2014-03-15 16:41:08

标签: php phpexcel

我有一个包含13列和5行的简单工作表。当我申请$ sheet-> removeColumn(' F',8);标头被替换为空字符串而不是被删除,并且正文行保持不变。有什么想法吗?

在removeColumn之前转储:

...

[3]=> array(13) { 
[0]=> string(8) "Apellido" 
[1]=> string(6) "Nombre" 
[2]=> string(11) "English Use" 
[3]=> string(9) "Listening" 
[4]=> string(5) "Nivel" 
[5]=> string(5) "Grupo" 
[6]=> string(14) "Valor por hora" 
[7]=> string(9) "Duración" 
[8]=> string(11) "Valor Sence" 
[9]=> string(15) "Costo Adicional" 
[10]=> string(11) "Valor Total" 
[11]=> string(7) "Horario" 
[12]=> string(8) "Profesor" 
} 
[4]=> array(13) { 
[0]=> string(10) "Estudiante" 
[1]=> string(5) "Nuevo" 
[2]=> string(3) "N/A" 
[3]=> string(3) "N/A" 
[4]=> string(7) "Starter" 
[5]=> string(3) "N/A" 
[6]=> string(3) "N/A" 
[7]=> string(3) "N/A" 
[8]=> string(3) "N/A" 
[9]=> string(3) "N/A" 
[10]=> string(3) "N/A" 
[11]=> string(3) "N/A" 
[12]=> string(3) "N/A" 

}

$sheet->removeColumn('F', 8);

removeColumn后转储:

...
[3]=> array(13) { 
[0]=> string(8) "Apellido" 
[1]=> string(6) "Nombre" 
[2]=> string(11) "English Use" 
[3]=> string(9) "Listening" 
[4]=> string(5) "Nivel" 
[5]=> string(0) "" 
[6]=> string(0) "" 
[7]=> string(0) "" 
[8]=> string(0) "" 
[9]=> string(0) "" 
[10]=> string(0) ""
[11]=> string(0) "" 
[12]=> string(0) "" 
} 
[4]=> array(13) { 
[0]=> string(10) "Estudiante" 
[1]=> string(5) "Nuevo" 
[2]=> string(3) "N/A" 
[3]=> string(3) "N/A" 
[4]=> string(7) "Starter" 
[5]=> string(3) "N/A" 
[6]=> string(3) "N/A" 
[7]=> string(3) "N/A" 
[8]=> string(3) "N/A" 
[9]=> string(3) "N/A" 
[10]=> string(3) "N/A" 
[11]=> string(3) "N/A" 
[12]=> string(3) "N/A" 
} 

0 个答案:

没有答案