Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Expression Returns an error.

Status
Not open for further replies.

melisc

Programmer
Feb 6, 2004
15
US
Thank you for your help. I entered the expression from this point on and entered it as an Expression Builder on the After Update command.

Nz(DLookup("[countyID]","locations","location ID]='" & Form!ReceiptEntry.[County ID] & "'"),"")

Did I miss something because it is returning an error that reads the following:


The expression After Update you entered as the event property setting produced the following error: The object you referenced in the Visual Basic procedure as an OLE object isn't an OLE object.

* The expression may not result in the name of a macro, the name of a user-defined function, or {Event Procedure].

* There may have been an error evaluating the function, event, or macro.

I have read and read and read and there seems to be little explanation in my Access 2000 book that explains this process well. Thanks again for your assistance.
 
Did you place this expression in the After Update property or did you open a code window and add some code to the After Update event?

Duane
MS Access MVP
Find out how to get great answers faq219-2884.
 
I haven'y seen the whole post but this formula does seem right.

Nz(DLookup("[countyID]","locations","location ID]='" & Form!ReceiptEntry.[County ID] & "'"),"")

1st you are missing [ from Location ID and as I can't see the rest of the code before this I can't be sure but the rest of the where doesn't look right at all " & Form!ReceiptEntry.[County ID] & "'").

if this is ereferencing the form it should be
[location ID]= Form!ReceiptEntry.[County ID]

Sorry can't be more help without more info.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top