Green error ? double you tee eff ?

Discussion in 'Programming General' started by darthvador91, Nov 7, 2007.

Green error ? double you tee eff ?
  1. Unread #1 - Nov 7, 2007 at 2:58 PM
  2. darthvador91
    Joined:
    Sep 15, 2007
    Posts:
    536
    Referrals:
    0
    Sythe Gold:
    0

    darthvador91 Forum Addict
    Banned

    Green error ? double you tee eff ?

    Ok , when i try to run my autoclicker in the source debugger i get this error

    A call to PInvoke function 'WindowsApplication1!WindowsApplication1.Form1::mouse_event' 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.

    here is the line of code that is highlighted green

    Code:
    mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0)
    now, when i run it in the .exe in the bin i works fien , but i would really like to correct this


    any infio PLEASE???
     
  3. Unread #2 - Nov 7, 2007 at 4:43 PM
  4. laxattack5
    Joined:
    Apr 6, 2007
    Posts:
    239
    Referrals:
    0
    Sythe Gold:
    0

    laxattack5 Active Member
    Banned

    Green error ? double you tee eff ?

    hey lol u stole double u tee eff from my post =P well anyway im pretty sure cuz of the 0, 0, 0, 0
     
  5. Unread #3 - Nov 7, 2007 at 5:12 PM
  6. darthvador91
    Joined:
    Sep 15, 2007
    Posts:
    536
    Referrals:
    0
    Sythe Gold:
    0

    darthvador91 Forum Addict
    Banned

    Green error ? double you tee eff ?

    i guess it doesnt rly matter , it works fine in .exe :)
     
  7. Unread #4 - Nov 7, 2007 at 6:43 PM
  8. skate4lifee
    Joined:
    Jul 22, 2007
    Posts:
    108
    Referrals:
    1
    Sythe Gold:
    0

    skate4lifee Active Member

    Green error ? double you tee eff ?

    i told you after i posted the code that it works fine if you ran the Binary.
     
  9. Unread #5 - Nov 7, 2007 at 7:23 PM
  10. darthvador91
    Joined:
    Sep 15, 2007
    Posts:
    536
    Referrals:
    0
    Sythe Gold:
    0

    darthvador91 Forum Addict
    Banned

    Green error ? double you tee eff ?

    yeh i know , but im just curious why it doesnt work in debugging mode
     
  11. Unread #6 - Nov 7, 2007 at 8:42 PM
  12. Flaming Idiots
    Joined:
    Dec 22, 2005
    Posts:
    235
    Referrals:
    1
    Sythe Gold:
    0
    Two Factor Authentication User

    Flaming Idiots Active Member
    Visual Basic Programmers

    Green error ? double you tee eff ?

    The reason is that you are probably using the Visual Basic 6 call for it. When converting native methods from VB6 to .NET, you need to change the number types from Long to Integer.

    VB6 way:
    Declare Sub mouse_event Lib "user32" (ByVal dwFlags As Long, ByVal dx As Long, ByVal dy As Long, ByVal cButtons As Long, ByVal dwExtraInfo As Long)

    VB.NET way:
    Declare Sub mouse_event Lib "user32" (ByVal dwFlags As Integer, ByVal dx As Integer, ByVal dy As Integer, ByVal cButtons As Integer, ByVal dwExtraInfo As Integer)
     
  13. Unread #7 - Nov 7, 2007 at 10:33 PM
  14. darthvador91
    Joined:
    Sep 15, 2007
    Posts:
    536
    Referrals:
    0
    Sythe Gold:
    0

    darthvador91 Forum Addict
    Banned

    Green error ? double you tee eff ?

    WOW your smart

    It works!

    Thank you so much EVERYONE who has helped me with this :)
     
< basic sendkeys function | Can anyone overlook my C++ program and correct me please? (VERY NOOB!!) >

Users viewing this thread
1 guest


 
 
Adblock breaks this site