Mouse function

I was hoping somebody could help me with this issue.

I am trying to write a program in C++ Builder that will capture the mouse coordinates. I don't know how to capture the coordinates or make the mouse pointer click/ double click etc. In C++ builder the TCustomGrid component has the functions that I need. However, when I try to create a descendant of it I get an error saying Class 'classname' is abstract because of '__fastcall.....' This is error #2353. I am not sure how to override like what they say...but I would appreciate it if somebody could tell me how to get around this problem. Or any other alternative to capturing the mouse position would be a solution to me as well. I don't care as long as I can get my program to do that.

Thanks.

-Fayez

Comments

  • : I was hoping somebody could help me with this issue.
    :
    : I am trying to write a program in C++ Builder that will capture the mouse coordinates. I don't know how to capture the coordinates or make the mouse pointer click/ double click etc. In C++ builder the TCustomGrid component has the functions that I need. However, when I try to create a descendant of it I get an error saying Class 'classname' is abstract because of '__fastcall.....' This is error #2353. I am not sure how to override like what they say...but I would appreciate it if somebody could tell me how to get around this problem. Or any other alternative to capturing the mouse position would be a solution to me as well. I don't care as long as I can get my program to do that.
    :
    : Thanks.
    :
    : -Fayez
    :
    Do you need capture mouse events for your application only or for Windows desktop?
    If for the application. Why you want use TCustomGrid? Use TStringGrid or something.
    If for the desktop, use TMouse class or hooking functions WinAPI (SetWindowsHookEx).



  • : : I was hoping somebody could help me with this issue.
    : :
    : : I am trying to write a program in C++ Builder that will capture the mouse coordinates. I don't know how to capture the coordinates or make the mouse pointer click/ double click etc. In C++ builder the TCustomGrid component has the functions that I need. However, when I try to create a descendant of it I get an error saying Class 'classname' is abstract because of '__fastcall.....' This is error #2353. I am not sure how to override like what they say...but I would appreciate it if somebody could tell me how to get around this problem. Or any other alternative to capturing the mouse position would be a solution to me as well. I don't care as long as I can get my program to do that.
    : :
    : : Thanks.
    : :
    : : -Fayez
    : :
    : Do you need capture mouse events for your application only or for Windows desktop?
    : If for the application. Why you want use TCustomGrid? Use TStringGrid or something.
    : If for the desktop, use TMouse class or hooking functions WinAPI (SetWindowsHookEx).
    :
    :
    :
    :

    Thanks for the help. Right after I posted the message I discovered that I can use the TMouse class. Right now I am at a point where I can capture the coordinates of the mouse location using CursorPos. However, I could not find anything to emulate a left click. I want to be able to make the mouse do a left click on some buttons automatically at certain intervals anywhere on the windows desktop.

    Thanks again and where can I find info about hooking functions?

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories