Keresés

Új hozzászólás Aktív témák

  • poffsoft

    veterán

    válasz Belnir #29469 üzenetére

    Option Explicit

    Public aktualis

    Private Sub Worksheet_Change(ByVal Target As Range)
    Dim lastrow As Long
    Dim akt_lap As String: akt_lap = ActiveSheet.Name
    Dim fso As Object
    Dim logfile As Object

    ' If Target.Count <> 1 Then Exit Sub
    ' If aktualis = Target.Value Then Exit Sub
    Application.ScreenUpdating = False
    Set fso = CreateObject("Scripting.FileSystemObject")
    Set logfile = fso.OpenTextFile("\eleresi_ut\log.txt", 8, True)
    logfile.WriteLine ("VÁLTOZTAT" & " - " & Format(Now, "YYYY.MM.DD hh:mm:ss") & " - " & Environ$("username") & " - " & Application.UserName & " - " & Environ$("computername") & " - " & Target.Parent.Name & " - " & Target.Address & " - " & aktualis & " - " & Target(1, 1).Value & " -+")
    logfile.Close
    Set logfile = Nothing
    Set fso = Nothing

    Application.ScreenUpdating = True
    End Sub

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    aktualis = ActiveCell.Value
    End Sub
    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    aktualis = ActiveCell.Value
    End Sub

Új hozzászólás Aktív témák

Hirdetés