I solved it myself here's how it's done. You will need to use jAWTRobot library for this to work.
B4X:
Private AWTRobot As AWTRobot
Private s As Screen
Private x,y As Int
' Read Mouse Cursor Position X & Y
Private m() As Int = AWTRobot.RobotMouseCurrentLocation
x = m(0)
y = m(1)
' Get Primary Monitor
s = fx.PrimaryScreen
' When within Primary Monitor and Mouse Boundaries
If s = fx.PrimaryScreen And x >=0 And x <= primaryWidth Then
'Do stuff...
End If