Hi there,
I'm trying to use GetCursorPos and it points to a POINT structure that receives the screen coordinates of the cursor.
Here's my code but I can't get it work with C++ though it worked with VB!! I actually have a problem with the POINT structure.
Tnx in advance,Code:#include <vcl.h> #pragma hdrstop #include "Unit1.h" #include "winuser.h" #include "windef.h" #pragma package(smart_init) #pragma resource "*.dfm" TForm1 *Form1; __fastcall TForm1::TForm1(TComponent* Owner) : TForm(Owner) { } typedef lp1 *tagPOINT; void __fastcall TForm1::Button1Click(TObject *Sender) { long retval; retval = GetCursorPos(lp1); }
See you,
keetsh




Reply With Quote