You seem to be inserting data into one form from another. What is unclear is whether those forms are bound or not. If bound, as would be usual in a sales orders/invoices database, you should not be referencing the forma at all, but using a query to retrieve values directly from the tables. This is how my InvoicePDF demo works, based on the following model:
As you can see this model allows data to be inserted directly into the Invoices and related tables. This is because the demo is designed to illustrate how to output reports (invoices) as PDF files, and is this a simplified model. More usually an operational database of this nature would allow data to be inserted into an orders and related tables. Invoice creation would then follow one of two basic models:
- In the simplest model it is assumed that each invoice mirrors a sales order exactly. In this scenario there is no data stored in a separate Invoice table, as the invoice report can be based directly on the Orders and related tables. The Orders table would include Invoiced, InvoiceDate, and InvoicePaid columns.
- A more complex model includes separate Invoices and related tables. This allows an invoice to be raised for partial or and/or multiple orders. Each invoice is built by copying the relevant key values from the Orders and related tables by means of 'append' queries.
You can of course have a model which is somewhere between the above two options, and includes an Invoices and related tables, but with less data inserted from the Orders table and its related tables. The exact model is determined by your business practices.
Whichever model is used, the point is that the invoice report is based on a query drawing data from the tables, with no reference to forms other than as parameters to restrict the result of the query. Consequently, it is possible to restrict the report in many different ways, so outputting multiple invoices as a single report becomes a simple task, as the sample query I gave you in my last reply illustrates.