Windows can support a one-button, two-button, or three-button mouse or use a joystick or light pen to mimic a one-button mouse. The support of a second and third mouse button is rarely exploited, however. Unless you know your Windows program will run only on machines equipped with a two-button or three-button mouse, you must write programs for the lowest common denominator and use only a single button.
You can determine if a mouse is present by using the GetSystemMetrics function:
fMouse = GetSystemMetrics (SM_MOUSEPRESENT) ;
The value of fMouse will be TRUE (nonzero) if a mouse is installed. No method is documented for determining the number of buttons on the installed mouse.