help

A

alxw3

during the load, using this code in subform causes the selection be set to
last record. how change this to set the selection to first record instead?.

Form_Current()
Me.Parent.insname = Me.insname

Form_Load()
DoCmd.GoToRecord , , acFirst
Me.Parent.no1 = Me.no
DoCmd.GoToRecord , , acLast
Me.Parent.no2 = Me.no
DoCmd.GoToRecord , , acFirst
Me.Parent.insname = Me.insname
 
K

Ken Snell MVP

Your question is not clear. You want to set "which selection" to the first
record? What do you mean by selection?
 
A

alxw3 via AccessMonster.com

i mean the record indicator symbol, in the left margin of the subform goes to
last record instead of the first record.
Your question is not clear. You want to set "which selection" to the first
record? What do you mean by selection?
during the load, using this code in subform causes the selection be set to
last record. how change this to set the selection to first record
[quoted text clipped - 10 lines]
DoCmd.GoToRecord , , acFirst
Me.Parent.insname = Me.insname
 
K

Ken Snell MVP

Try this code:

Private Sub Form_Load()
With Me.RecordsetClone
.MoveFirst
Me.Parent.no1 = .no
Me.Parent.insname = .insname
.MoveLast
Me.Parent.no2 = .no
End With
End Sub

--

Ken Snell
<MS ACCESS MVP>
http://www.accessmvp.com/KDSnell/


alxw3 via AccessMonster.com said:
i mean the record indicator symbol, in the left margin of the subform goes
to
last record instead of the first record.
Your question is not clear. You want to set "which selection" to the first
record? What do you mean by selection?
during the load, using this code in subform causes the selection be set
to
last record. how change this to set the selection to first record
[quoted text clipped - 10 lines]
DoCmd.GoToRecord , , acFirst
Me.Parent.insname = Me.insname
 
Top