Mega Code Archive

 
Categories / Delphi / VCL
 

Detecting if a mouse has a wheel

Question: How can I detect if the currently installed mouse has a wheel? Answer: By taking advantage of the new global mouse object which contains information relating to the mouse. The mouse object has a boolean property called "WheelPresent" which is true if a mouse wheel is present or false if none is detetced.