WinAPI: GetCursorPos - 获取鼠标指针的当前位置

//声明:
GetCursorPos(
  var lpPoint: TPoint {POINT 结构指针, 接收鼠标指针的屏幕坐标}
): BOOL;

 
 
 
 
 

 

 
  

//举例:
var
  pt: TPoint;
begin
  GetCursorPos(pt);
  ShowMessage(Format('ScreenX: %d; ScreenY: %d', [pt.X, pt.Y]));
end;

 
 
 
 
 

 

 
  

你可能感兴趣的:(WinAPI: GetCursorPos - 获取鼠标指针的当前位置)