SteveL13
asked on
Make a form open to the right hand side of the user's monitor
Is there a way to make a form open to the right hand side of the user's monitor? Or do they have to manually move it every time they open it?
ASKER
Jim, I don't seem to be able to make this work. I copy/pasted this in a public module:
And pasted this in the onopen event of the form:
Declare Function GetSystemMetrics32 Lib "user32" _
Alias "GetSystemMetrics" (ByVal nIndex As Long) As Long
And pasted this in the onopen event of the form:
Private Sub Form_Open(Cancel As Integer)
MonitorW = GetSystemMetrics32(0) * 1440 / 96
MonitorH = GetSystemMetrics32(1) * 1440 / 96
Me.Move 600, 600, MonitorW - 1200, MonitorH - 2000
End Sub
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Open in new window
Using the Move to place the form where you wanted.
Jim.