Snappy2873
Programmer
Hello Everyone,
First of all,
I have a tracking_no table and a tracking_no form that displays all the records from this table. This table is populated with new data dependent upon each records stage in the record life cycle. For example, a form is filled out and a new id is generated at the click, once there is an id, there is an "account" and all new account information is stored in this tracking_no table. In the "onformat" event in the form properties, this code basically sets the recordset to the most recent id created as to set the stage for the next id.
So at the click of the "generate invoice" button, i call the tracking number form in a "control" cmd statement, this form will then populate a report called "new invoice". Here lies the problem, when generating a new id and then report i get an error when processing the new id's in succession. To avoid this error i have to generate an id and then get out then get back in. Am i missing a refresh statement? Any ideas would be greatly appreciated!!
Thanks,
snappy
First of all,
I have a tracking_no table and a tracking_no form that displays all the records from this table. This table is populated with new data dependent upon each records stage in the record life cycle. For example, a form is filled out and a new id is generated at the click, once there is an id, there is an "account" and all new account information is stored in this tracking_no table. In the "onformat" event in the form properties, this code basically sets the recordset to the most recent id created as to set the stage for the next id.
Code:
Private Sub Form_Load()
DoCmd.GoToRecord , , acFirst
End Sub
So at the click of the "generate invoice" button, i call the tracking number form in a "control" cmd statement, this form will then populate a report called "new invoice". Here lies the problem, when generating a new id and then report i get an error when processing the new id's in succession. To avoid this error i have to generate an id and then get out then get back in. Am i missing a refresh statement? Any ideas would be greatly appreciated!!
Thanks,
snappy