Sorry - this is probably a simple question...

This is a discussion on Sorry - this is probably a simple question... within the C++ Programming forums, part of the General Programming Boards category; how do you get if the mouse is being pressed, and where it is? I know I probably sound like ...

  1. #1
    new person
    Guest

    Question Sorry - this is probably a simple question...

    how do you get if the mouse is being pressed, and where it is? I know I probably sound like a newbie right now, and I am... so...

  2. #2
    I lurk
    Join Date
    Aug 2002
    Posts
    1,361
    Not possible.
    You'll need to use an API (Application Programming Interface) to achieve this... like the Win32 API. #include <windows.h>

    Although I suggest you stick to console applications until you learn the language, there's some amazing Win32 tutorials at www.sunlightd.com

  3. #3
    Registered User WebSnozz's Avatar
    Join Date
    Oct 2001
    Posts
    102
    If you get familiar with win api from that site he linked ... The mouse button information is included in one of the paramaters passed to the callback function.

    Something I did when learning win32 api was left the console window enabled and every msg pump loop I would clear the screen and output in hex and integer format the hi and lo order parameters, you can watch them change as you move your move over the window and click, drag, click and hold, etc.
    WebSnozz-
    Cats have no butt cheeks.
    If one farted, then it would make a flute noise.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Simple question regarding variables
    By Flakster in forum C++ Programming
    Replies: 10
    Last Post: 05-18-2005, 08:10 PM
  2. Simple class question
    By 99atlantic in forum C++ Programming
    Replies: 6
    Last Post: 04-20-2005, 11:41 PM
  3. Simple question about pausing program
    By Noid in forum C Programming
    Replies: 14
    Last Post: 04-02-2005, 08:46 AM
  4. simple question.
    By InvariantLoop in forum Windows Programming
    Replies: 4
    Last Post: 01-31-2005, 11:15 AM
  5. simple fgets question
    By theweirdo in forum C Programming
    Replies: 7
    Last Post: 01-27-2002, 05:58 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21