Problem VB

sm950

Użytkownik
Dołączył
Sierpień 8, 2012
Posty
62
Witam

Mam taki problem otóż znalazłem na youtbie filmik z keylogerem i chciałem takiego samego napisać żeby go przetestować ale natknąłem się na pewien problem odnośnie taki:

taki komunikat mi wyskakuje:

A call to PInvoke function 'Keylogger!Keylogger.Form1::GetAsyncKeyState' has unbalanced the stack. This is likely because the managed PInvoke signature does not match the unmanaged target signature. Check that the calling convention and parameters of the PInvoke signature match the target unmanaged signature.

A kod jest taki:
Kod:
Public Class Form1
    Dim result As Integer
    Private Declare Function GetAsyncKeyState Lib "user32" (ByVal vkey As Long) As Integer

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
        For i = 1 To 255
            result = 0
            result = GetAsyncKeyState(i)
            If result = -32767 Then
                TextBox1.Text = TextBox1.Text + Chr(i)

            End If
        Next i

    End Sub
End Class
 

trojanxem

Użytkownik
Dołączył
Grudzień 6, 2011
Posty
239
To Ty piszesz w C++, czy w basicu? Wrzucasz srednio raz na tydzień jakiś strzępek gotowego kodu którego nie rozumiesz, kolego nie tędy droga, zacznij od podstaw...
 
Do góry Bottom