Commit 963075bb authored by Marc Egger's avatar Marc Egger
Browse files

Fixes #8149 Excel Export cutoff at Column AA

parent e00853d2
Pipeline #1782 passed with stage
in 2 minutes and 15 seconds
......@@ -173,24 +173,16 @@ class Excel {
}
/**
* Increment the alpha string. If 'Z' is reached on the last position, it appends 'A'.
* Increment the alpha string. i.e. count using A-Z as base.
* 'A' > 'B'
* 'Z' > 'ZA'
* 'ZA' > 'ZB'
* 'Z' > 'AA'
* 'AA' > 'AB'
* 'AGTC' > 'AGTD'
*
* @param $column
* @return string - incremented column.
*/
private function nextColumn($column) {
$len = strlen($column);
$c = $column[$len - 1];
if ($c == 'Z') {
$column .= 'A';
} else {
$c = ++$c;
$column[$len - 1] = $c;
}
return $column;
return ++$column;
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment