Simple fix

This commit is contained in:
Ricardo Montañana Gómez 2023-10-28 10:56:47 +02:00
parent 5a3af51826
commit 92820555da
Signed by: rmontanana
GPG Key ID: 46064262FD9A7ADE

View File

@ -21,11 +21,10 @@ namespace platform {
string getColumnName(int colNum)
{
string columnName = "";
int modulo;
if (colNum == 0)
return "A";
while (colNum > 0) {
modulo = colNum % 26;
int modulo = colNum % 26;
columnName = char(65 + modulo) + columnName;
colNum = (int)((colNum - modulo) / 26);
}