I would check that your argString split is working by debug.print them in order as they are fired. I would assume if the form is blank then the values aren't being passed.
It occurs to me however that if most of this data is already stored you probably don't need to enter it on another form ?
You also mentioned a query in your first post - how does that fit in with this process?
Right I've changed all this round now and still it's not working.
This is what I have now.
I have a form which displays records from a table in a continuous way (like a spreadsheet).
When the first field (of each line) is added the AfterUpdate event is kicked off and it is checked for certain conditions and if they apply then a second form is loaded.
If Me.[Component ID] = 1 Then
args = Me.txtEmpName & "|" & Me.txtRMANo & "|" & Me.txtComponentPartNo & "|" & _
Me.txtSerialNo & "|" & Me.txtJobID & "|" & Me.txtDescription & "|" & _
Me.txtEmpID & "|" & Me.txtID & "|" & Me.txtCustomer & "|" & Me.Component_Part_No
DoCmd.OpenForm "Component Swaps", , , , , , args
End If
I pass over, amongst other things, the ID from table 1 which is a foreign key to a second table. This is defined as Me.txtID.
The 2nd forms fills in parts of the form from the data passed over leaving the user to fill in about 3 fields himself.
The load event on the second form contains
If Not IsNull(Me.OpenArgs) Then
argString = Split(Me.OpenArgs, "|", 11)
Me.txtEmpName = argString(0)
Me.txtRMANo = argString(1)
Me.txtComponentPartNo = argString(2)
Me.txtSerialNo = argString(3)
Me.txtJobID = argString(4)
Me.txtDescription = argString(5)
Me.txtEmployeeID = argString(6)
Me.txtEmpID = argString(6)
Me.txtJobPartID = argString(7)
Me.txtCustomer = argString(8)
Me.ModelNumber = argString(9)
Me.txtSwapDate = Now()
End If
Now I've step through all of this and all the fields are populated with the right values.
When the user comes to save this (via a button) I get an error message stating "you can not add or change a record because a related record is required in table "X"
I presumed that the table had been updated as the after update event occurred.
The data from the 1st form comes from a query rather than a table itself, but I though if data was updated in a query it was reflected in the table itself.
Hope this is all clear