Here you go...
Private Sub logchange(ByVal source As Object, ByVal e As
System.IO.FileSystemEventArgs)
If e.ChangeType = IO.WatcherChangeTypes.Changed
Then
txt_folderactivity.Text &= vbCrLf & strUser
& " on " & strComputer & " - File " & e.FullPath & _
" has been modified - " & Now()
SaveTextToFile
(txt_folderactivity.Text, "c:\Log.txt")
End If
If e.ChangeType = IO.WatcherChangeTypes.Created
Then
txt_folderactivity.Text &= vbCrLf & strUser
& " on " & strComputer & " - File " & e.FullPath & _
" has been created - " & Now()
SaveTextToFile
(txt_folderactivity.Text, "c:\Log.txt")
End If
If e.ChangeType = IO.WatcherChangeTypes.Deleted
Then
txt_folderactivity.Text &= vbCrLf & strUser
& " on " & strComputer & " - File " & e.FullPath & _
" has been deleted - " & Now()
SaveTextToFile
(txt_folderactivity.Text, "c:\Log.txt")
End If
End Sub
Public Sub logrename(ByVal source As Object, ByVal e
As System.IO.RenamedEventArgs)
txt_folderactivity.Text &= vbCrLf & strUser & "
on " & strComputer & " - File " & e.OldName & _
" has been renamed to " & e.Name & vbCrLf
SaveTextToFile
(txt_folderactivity.Text, "c:\Log.txt")
End Sub