'后台鼠标单击
Sub BackMmouseClick(sHWnd as HWnd, X as Long, Y as Long, Bun as Long = 1) '后台鼠标单击
   Dim xy as DWord
   'xy=Mak(DWORD, x, y)
   xy = y * 65536 + x
   'xy=Shl(y,16)
   If Bun = 1 Then '左键
      PostMessage sHWnd, WM_LBUTTONDOWN, MK_LBUTTON, xy
      'DoEvents
      PostMessage sHWnd, WM_LBUTTONUP, MK_LBUTTON, xy
   Else
      PostMessage sHWnd, WM_RBUTTONDOWN, MK_RBUTTON, xy
      'DoEvents
      PostMessage sHWnd, WM_RBUTTONUP, MK_RBUTTON, xy
      
   End If
   
End Sub
