I have a text box: mouseposition
When the mouse is clicked on a form I would like the value of
mouseposition.text to represent the position of the mouse.
This could be relatively simple, depending on what you need. You'd use
the MouseDown event, but be aware that the form itself has a MouseDown
event and each section of the form has a MouseDown event. The form's
event isn't much good, as it pretty much only fires if someone presses a
mouse button on the record selector. probably you want to use the
form's Detail section's event:
'----- start of code -----
Private Sub Detail_MouseDown( _
Button As Integer, _
Shift As Integer, _
X As Single, _
Y As Single)
Me!MousePosition = X & ", " & Y
End Sub
'----- end of code -----