Paul Wagner
Registered User.
- Local time
- Today, 14:23
- Joined
- May 18, 2004
- Messages
- 48
I've heard that you can't get access in the vb code to any of the fields in an OpenQuery and that you either have to do a DLookup. Yet here in some production code I found that the field [annualizedcharges] is being stuffed back into an update table. When I use "msg [annualizedcharges] the program just hangs as though it doesn't recognize the syntax.
Is the field available in the code and if so how?
DoCmd.OpenQuery "qryAnnualizedCollections"
strSQL = "UPDATE (tblFacultyBudgetHeader " & _
"INNER JOIN tblAnnualizedCharges ON tblFacultyBudgetHeader.FacultySSN = tblAnnualizedCharges.SSN) " & _
"INNER JOIN tblFacultyBudgetDetail ON tblFacultyBudgetHeader.BudgetNumber = tblFacultyBudgetDetail.BudgetNumber " & _
"SET " & strFieldName & "= [annualizedcharges] " & _
"WHERE (((tblFacultyBudgetDetail.AccountTypeCode)='PS-GC'))"
TIA
Paul
Is the field available in the code and if so how?
DoCmd.OpenQuery "qryAnnualizedCollections"
strSQL = "UPDATE (tblFacultyBudgetHeader " & _
"INNER JOIN tblAnnualizedCharges ON tblFacultyBudgetHeader.FacultySSN = tblAnnualizedCharges.SSN) " & _
"INNER JOIN tblFacultyBudgetDetail ON tblFacultyBudgetHeader.BudgetNumber = tblFacultyBudgetDetail.BudgetNumber " & _
"SET " & strFieldName & "= [annualizedcharges] " & _
"WHERE (((tblFacultyBudgetDetail.AccountTypeCode)='PS-GC'))"
TIA
Paul