Help!!!
I have a form where when I press a button to print tjhe form,
several things take place.
1) Data is saved
2) A new form is to open up
3) The new form cursor should start at a particular place
The problem is that everything works sometimes!
Sometimes I get an ERROR MESSAGE:
YOU CAN'T GO TO THE SPECIFIED REORD
YOU MAY BE AT THE END OF A RECORD SET
I have a manual button that creates a new record (Blank Form) and that works just fine.
The code for the print button I have is as follows:
Private Sub Command23_Click()
On Error GoTo Err_Command23_Click
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
DoCmd.PrintOut acSelection
DoCmd.GoToRecord , , acNext
DoCmd.GoToControl "ETR Number"
Exit_Command23_Click:
Exit Sub
Err_Command23_Click:
MsgBox Err.Description
Resume Exit_Command23_Click
End Sub
This is perplexing!
Please help!
C.Segal
csegal@arrowair.com
I have a form where when I press a button to print tjhe form,
several things take place.
1) Data is saved
2) A new form is to open up
3) The new form cursor should start at a particular place
The problem is that everything works sometimes!
Sometimes I get an ERROR MESSAGE:
YOU CAN'T GO TO THE SPECIFIED REORD
YOU MAY BE AT THE END OF A RECORD SET
I have a manual button that creates a new record (Blank Form) and that works just fine.
The code for the print button I have is as follows:
Private Sub Command23_Click()
On Error GoTo Err_Command23_Click
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
DoCmd.PrintOut acSelection
DoCmd.GoToRecord , , acNext
DoCmd.GoToControl "ETR Number"
Exit_Command23_Click:
Exit Sub
Err_Command23_Click:
MsgBox Err.Description
Resume Exit_Command23_Click
End Sub
This is perplexing!
Please help!
C.Segal
csegal@arrowair.com