Subform Pulling Form info

Valentine

Member
Local time
Today, 18:27
Joined
Oct 1, 2021
Messages
261
I am trying to insert into a table from a subform.
Code:
DoCmd.RunSQL "INSERT INTO [CdgrToCidr] ([CDGR ID#], [Fulfillment Status], [CDGR Title], [Parent CDGR ID#]) values ('" & Me.txtCdgrId.Value & "', 'JCRB Validated', '" & Forms(CNF Input).txtCnfTitle.Value &"', 'None')"
Nothing happens and I have widdled it down to the Forms(CNF Input) part of the code that isnt working but i might be wrong.
 
Put it all into a string variable and then debug.print that variable.
When eventually correct, use that for the runsql

BTW, you do not need the .Value suffix
 
I think it should be
Forms("CNF Input").txtCnfTitle

Or
Forms![CNF Input]!txtCnfTitle
 
I am sooooooo bad with typos!!!!!! grrrr I had it fine but with a fat fingered letter.
 

Users who are viewing this thread

Back
Top Bottom