The MoveSize command looks like what I want. I can't seem to get it to
work
though. I'm using the following code:
Private Sub Form_BeforeUpdate(Cancel As Integer)
If Me![Customer] = "Mutual" And IsNull(Me![Returns]) Then
MsgBox "You must enter Returns."
Cancel = True
[Returns].SetFocus
End If
End Sub
when the above code is activated, that's when I want the [Returns]
field
to
be in the center of the screen. I've tried putting the code in a couple
different places, but can't seem to get it to work.
I've written the following:
DoCmd.MoveSize([0], [700], [0], [0])
:
Did you want to move a textbox relative to the form, or the form
relative
to
the Access window?
The Top and Left properties of a textbox will move it relative to the
form.
The MoveSize Method will move the form relative to the Access window,
as
in:
DoCmd.MoveSize 1440, 2400, , 2000
The syntax is:
DoCmd.MoveSize
[, down][, width][, height]
and all measurements are in Twips (1440 Twips to the inch)
--
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com
I'm wondering if it's possible to center a field with set focus.
Right
now,
the field on my form appears at the top of the screen--is it
possible
to
center it (I have a multi-page form).
Thank you
.