Subform field link

MikeLeBen

Still struggling
Local time
Today, 23:12
Joined
Feb 10, 2011
Messages
187
Main form's record source:
Code:
SELECT Clienti_Ricette.*, Pagamenti.* FROM Clienti_Ricette, Pagamenti

The subform is a datasheet meant to view and possibly enter new records in the table Pagamenti.

subform's record source (from the afterupdate of a cbo in the main form):
Code:
mysql = "SELECT Pagamenti.* FROM Pagamenti " & _
        "WHERE Pagamenti.IDCliente = " & Me.cboRicetteEsistenti.Column(0) & ";"
Me.frmPagamentiSub.Form.RecordSource = mysql
Me.frmPagamentiSub.Form.Visible = True

Now I selected that the Master field "Clienti_Ricette.IDCliente" be linked to the child field "IDCliente", so that when a new record is added, that field is automatically populated. For some reason, though, it stays blank. How can I fix this?
 
I am having the same problem. I modified my master query to have no .* field reference, but now my subform won't requery. Instead it prompts for the LinkMasterField, as if it doesn't exist
 

Users who are viewing this thread

Back
Top Bottom