ich hab eine Userhistory angelegt und verwende dazu diesen Quellcode.
Dim LoLetzte As Long
Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
Application.EnableEvents = False
Dim Netzwerk As Object
Set Netzwerk = CreateObject("wscript.network")
With Worksheets("History")
LoLetzte = IIf(IsEmpty(.Cells(.Rows.Count, 1)), .Cells(Rows.Count, 1).End(xlUp).Row, . _
Rows.Count) + 1
.Cells(LoLetzte, 1) = Target.Address
.Cells(LoLetzte, 2) = Target
.Cells(LoLetzte, 3) = Sh.Name
.Cells(LoLetzte, 4) = Environ("Username")
.Cells(LoLetzte, 5) = CStr(Date)
.Cells(LoLetzte, 6) = CStr(Time)
.Cells(LoLetzte, 7) = Netzwerk.computername
.Cells(LoLetzte, 8) = Netzwerk.UserName
End With
Application.EnableEvents = True
End Sub
Nun kommt die Krucks an der Geschichte. Ich hab einen Benutzer, der ständig ein Sheet komplett färbt und ich hab noch nicht herausgefunden, wer das macht.Aus diesem Grund schreibt nun mal die History mit, wer was wann wie ändert.
Nun fehlt mir noch die Formatierung.
Weiß von euch jemand, wie man das machen könnte?
Danke im Voraus und Gruß
Albert