All I have created an edit records query and an edit anwser query so people can edit answers to various questions once they have been entered. I have created 2 forms and the associate opens the Edit Answer form by clicking on a command button. This works great. However when they changes they select the question ID from the drop down menu they receive the error of no current record. Here is the SQL on the Answer Query and the VBA code for the form. Any help would be great.
SQL:
SELECT [Answers Table].Answer, [Answers Table].Observation, [Answers Table].RecordId, [Answers Table].Qid, [Question Table].[Question Number], [Question Table].[Question Title], [Question Table].[Question Text], [Question Table].[Has NA]
FROM [Question Table] INNER JOIN ([IQ 2] INNER JOIN [Answers Table] ON [IQ 2].RecordId = [Answers Table].RecordId) ON [Question Table].Qid = [Answers Table].Qid
WHERE ((([Answers Table].RecordId)=[Forms]![Edit Records]![RecordId]) AND (([Answers Table].Qid)=[Forms]![EditAnswer1]![Qid]));
The VBA is an On Change Event Procedure for the QID field
Private Sub Qid_Change()
[Forms]![EditAnswer1].Requery
End Sub
SQL:
SELECT [Answers Table].Answer, [Answers Table].Observation, [Answers Table].RecordId, [Answers Table].Qid, [Question Table].[Question Number], [Question Table].[Question Title], [Question Table].[Question Text], [Question Table].[Has NA]
FROM [Question Table] INNER JOIN ([IQ 2] INNER JOIN [Answers Table] ON [IQ 2].RecordId = [Answers Table].RecordId) ON [Question Table].Qid = [Answers Table].Qid
WHERE ((([Answers Table].RecordId)=[Forms]![Edit Records]![RecordId]) AND (([Answers Table].Qid)=[Forms]![EditAnswer1]![Qid]));
The VBA is an On Change Event Procedure for the QID field
Private Sub Qid_Change()
[Forms]![EditAnswer1].Requery
End Sub