🙏 Helfen Sie jetzt mit, unser LibreOffice Forum zu erhalten! 🙏
Mit Ihrer Spende sichern Sie den Fortbestand, den Ausbau und die laufenden Kosten dieses Forums. 🌱

🍀 Jeder Beitrag zählt – vielen Dank für Ihre Unterstützung!🍀

❤️ DANKE >> << DANKE ❤️

>> Dank Ihrer Unterstützung -> Keine Werbung für alle registrierten LibreOffice-Forum User! <<
🤗 Als Dankeschön werden Sie im Forum als LO-SUPPORTER gekennzeichnet. 🤗

VBA to libreoffice question

Alles zur Programmierung im LibreOffice.
Antworten
comandos
Beiträge: 2
Registriert: Mo 16. Mär 2020, 12:25

VBA to libreoffice question

Beitrag von comandos » Mo 16. Mär 2020, 12:28

Greetings,

I need a little help editing my existing VBA code to work with libre office.
I would like:
1) to copy errors in column C if the date in the same row in yellow,
2) sort them all by date oldest to newest
3) (if possible) if the button (that triggers the macro is pressed it clears any previous entries in “STATUS” tab).
https://imgur.com/a/GQVmEPv ← example

code

Code: Alles auswählen

Option Compare Text
Sub getAllErr()
    Dim ws As Worksheet
    Dim lastRow As Integer
    For Each ws In ThisWorkbook.Sheets
        If ws.Name <> "status" Then
            For i = ws.UsedRange.Rows.Count To 2 Step -1
                If ws.Cells(i, 1).Interior.Color = 65535 Then
                    lastRow = ThisWorkbook.Sheets("status").Cells(Rows.Count, 1).End(xlUp).Row
                    ThisWorkbook.Sheets("status").Cells(lastRow + 1, 1) = Format(ws.Cells(i, 1), "Short Date")
                    ThisWorkbook.Sheets("status").Cells(lastRow + 1, 2) = ws.Name
                    ThisWorkbook.Sheets("status").Cells(lastRow + 1, 3) = ws.Cells(i, 3)
                End If
            Next i
        End If
    Next ws
End Sub
MsgBox "Kopirano"
BR

F3K Total
* LO-Experte *
Beiträge: 2501
Registriert: So 10. Apr 2011, 10:10

Re: VBA to libreoffice question

Beitrag von F3K Total » Mo 16. Mär 2020, 18:26

Windows 11: AOO, LO Linux Mint: AOO, LO

comandos
Beiträge: 2
Registriert: Mo 16. Mär 2020, 12:25

Re: VBA to libreoffice question

Beitrag von comandos » Di 17. Mär 2020, 07:54

F3K Total hat geschrieben:
Mo 16. Mär 2020, 18:26
crossposting
My bad, still looking for help.

F3K Total
* LO-Experte *
Beiträge: 2501
Registriert: So 10. Apr 2011, 10:10

Re: VBA to libreoffice question

Beitrag von F3K Total » Di 17. Mär 2020, 18:22

we all lern...
solution in english forum available ...
R
Windows 11: AOO, LO Linux Mint: AOO, LO


An alle, die das LibreOffice-Forum gern nutzen und unterstützen wollen:


Bitte helfen Sie uns mit 7 Euro pro Monat.
Durch Ihren Beitrag tragen Sie dazu bei, unsere laufenden Kosten für die kommenden Monate zu decken.
Unkompliziert per Kreditkarte oder PayPal.
Als ein kleines Dankeschön werden Sie im LO-Forum als SUPPORTER gekennzeichnet.



Antworten