Date: prev next · Thread: first prev next last
2020 Archives by date, by thread · List index


Am 20.12.20 um 15:55 schrieb Bernd Obermayr:
 Die Funktionen zum ermitteln der letzten Zelle finden nur die erste
Zelle die wirklich leer ist (UsedRange)
Ich will aber die letzte Zelle deren angezeigter Inhalt nicht "" ist.
Weil da z.B eine Formel drinsteht:
=WENN(ISTZAHL(C63);LOG(2)/LOG(M63);"")


Hat da jemand eine elegante Lösung?


Hab genau das passende Werkzeug gefunden
com.sun.star.sheet.GeneralFunction.COUNTNUMS
Gibt die Anzahl der Zellen, die eine Zahl anzeigen, zurück

Weil in dem speziellen Fall wirklich nur Nummern oder "" in den Zellen
angezeigt werden,
ist das für mich die Lösung

Wenn auch text dort angezeigt wird ist wohl die Lösung in meiner letzten
Mail gefragt.

oSelektion = oSheet.getCellRangeByPosition(1,0,1,2000)
CountRows=oSelektion.computeFunction(com.sun.star.sheet.GeneralFunction.COUNTNUMS)

Aus der Doku: COUNTNUMS         numerical values are counted.
Siehe
<https://api.libreoffice.org/docs/idl/ref/namespacecom_1_1sun_1_1star_1_1sheet.html#ad184d5bd9055f3b4fd57ce72c781758d>

-- 
Gruss
  Bernd

-- 
Liste abmelden mit E-Mail an: users+unsubscribe@de.libreoffice.org
Probleme? https://de.libreoffice.org/hilfe-kontakt/mailing-listen/abmeldung-liste/
Tipps zu Listenmails: https://wiki.documentfoundation.org/Netiquette/de
Listenarchiv: https://listarchives.libreoffice.org/de/users/
Datenschutzerklärung: https://www.documentfoundation.org/privacy

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.