DLookup in Report (1 Viewer)

CTQE

Registered User.
Local time
Today, 09:24
Joined
Feb 27, 2008
Messages
48
Hello Everyone!,
A quick question to you folks...

What would be the correct DLookup syntax to perform the following operation:

I need to bring in a value from a field named "Description" from a table called "PNs and Desc". The "Description" should be relative to another field named "PN" (located in another table).

Any ideas?

Thnx in advance!
 

Treason

#@$%#!
Local time
Today, 12:24
Joined
Mar 12, 2002
Messages
340
=Dlookup("[Description]", "PNs and Desc", "[PN] = " & MyPNVar)

The hard part would be getting MyPNVar equal to the right record. if the PN is already on your form then you could do:

Dlookup("[Description]", "PNs and Desc", "[PN] = " & forms!myformname.PN)
 

Users who are viewing this thread

Top Bottom