SidLancing
Programmer
Hello again ScriVerb & PHV
I'm back with another question...
This time I have a Textbox (named SponsorName) that is a calculated field which is updated in the after_update event procedure of a combobox field (named StudyNum).
In the after_update of that field I have the following:
The problem is that SponsorName is blank on the screen.
I'm sure that it is calculated correctly in the Dlookup because the msgbox and the value in the table are correct.
Any Ideas what that might be ???
P.S... CP & JobNumForYear all display correctly on the screen. SponsorName is Text just like CP
Regards,
SidLancing
I'm back with another question...
This time I have a Textbox (named SponsorName) that is a calculated field which is updated in the after_update event procedure of a combobox field (named StudyNum).
In the after_update of that field I have the following:
Code:
Private Sub StudyNum_AfterUpdate()
JobNumforYear = DLookup("JobWithinyear", "Projectlog", "Company=" & [ReceivingCompanyID] & " And Study='" & [StudyNum] & "'")
Cur_YR = DatePart("yyyy", [OrderDate])
CP = DLookup("CustNum", "Company", " CompanyID=" & [ReceivingCompanyID]) & Cur_YR & "-" & JobNumforYear
SponsorName = DLookup("Sponsor", "Projectlog", "Company=" & [ReceivingCompanyID] & " And Study='" & [StudyNum] & "'")
MsgBox "The sponsor is " & SponsorName
Me.Refresh
End Sub
The problem is that SponsorName is blank on the screen.
I'm sure that it is calculated correctly in the Dlookup because the msgbox and the value in the table are correct.
Any Ideas what that might be ???
P.S... CP & JobNumForYear all display correctly on the screen. SponsorName is Text just like CP
Regards,
SidLancing