DLookup In Conjunction With MS Word

Rmaster

Rmaster
Local time
Today, 23:08
Joined
Mar 7, 2005
Messages
25
Hello all,

I have a query based on input from a word document. Now i want it to check if the data is the same as in the table but i cant get it work. You can see my query as attachmend. The name of the query is qryAchter2


My VBA Code is as follow
Code:
    If doc.FormFields("fldAchternaam").Result = DLookup "[tblAanvrager.Achternaam]", "[qryAchter2]") And doc.FormFields("fldGeboortedatum").Result = DLookup "[tblAanvrager.Geboortedatum]", "[qryAchter2]") Then
    PopUpMsgBox "Test ", , " Warning!!!", vbInformation
    Else

Can somebody help me to make this work

Thanks in advance
 

Attachments

  • query.GIF
    query.GIF
    7.8 KB · Views: 137
thanks for the reply

I solved it a other way
 

Users who are viewing this thread

Back
Top Bottom