Hi,
From the instructions in the link below I have made an example of how to copy data from main form into a suborm. This works just fine when you pressed the "Command 01" button.
However, how could I do exactly the same example but to click on the Command 02 button, so that button is on main form? I am having a problem setting up a code??
Before going in to how to do it, I have to ask why would you want to?
The whole point of relational databases is to enter data once and then refer to it.
That is what Queries are for, ie bringing together the data from various tables.
In fact, it’s just a test form so I understand how it works.
In reality, I want to have similar input mask where, when a button is clicked, certain data (not all) is transferred to the general ledger.
You do not need the Subform, unless you want it for display purposes to do the transfer.
It can be done directly to the table using a recordset.
I use that to balance stocks when sales are made and that kind of work.
Let me know if you want or need to do that kind of thing.