diff --git a/source/app/controllers/util.py b/source/app/controllers/util.py index 73cd8e6..16a174c 100644 --- a/source/app/controllers/util.py +++ b/source/app/controllers/util.py @@ -666,7 +666,11 @@ class LIBO(object): def _set_search(self): self._sheet = self._template.getSheets().getByIndex(0) - self._search = self._sheet.getPrintAreas()[0] + try: + self._search = self._sheet.getPrintAreas()[0] + except IndexError: + self._search = self._sheet.getRangeAddress() + self._search = self._sheet.getCellRangeByPosition( self._search.StartColumn, self._search.StartRow, diff --git a/source/db/valores_iniciales.json b/source/db/valores_iniciales.json index 1556317..107b880 100644 --- a/source/db/valores_iniciales.json +++ b/source/db/valores_iniciales.json @@ -27,7 +27,8 @@ {"key": "ACT", "name": "Actividad", "activo": false}, {"key": "KGM", "name": "Kilogramo", "activo": false}, {"key": "XBX", "name": "Caja", "activo": false}, - {"key": "XRO", "name": "Rollo", "activo": false} + {"key": "XRO", "name": "Rollo", "activo": false}, + {"key": "MTR", "name": "Metro", "activo": false} ] }, {