From f756a7cd67cfe6c73454a8619331340e087d03b5 Mon Sep 17 00:00:00 2001 From: selim Date: Tue, 26 Dec 2023 03:25:09 +0100 Subject: [PATCH] Spreadsheet getRow 3 character fix. --- Axel/src/de/hs_mannheim/informatik/spreadsheet/Spreadsheet.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Axel/src/de/hs_mannheim/informatik/spreadsheet/Spreadsheet.java b/Axel/src/de/hs_mannheim/informatik/spreadsheet/Spreadsheet.java index 8c8905b..8300eba 100644 --- a/Axel/src/de/hs_mannheim/informatik/spreadsheet/Spreadsheet.java +++ b/Axel/src/de/hs_mannheim/informatik/spreadsheet/Spreadsheet.java @@ -73,6 +73,8 @@ public class Spreadsheet { } private int getRow(String cellName) { + if(cellName.length()>2) + return Integer.parseInt(""+cellName.charAt(1)+cellName.charAt(2)) - 1; return cellName.charAt(1) - '1'; }