P
Paul.
Hi Everyone
I have the following expression in a field I add in the design view of a
query.
Basically I have a table of Contacts named "Contacts" with fields:
Contact Types : GM, Owner or Owner's Rep so it's text
Hotel: name of the hotel so text again, note that each contact is related to
an hotel
E-mail: e-mail address of the person
In a Query I import all the fields and add one called GMEmailAddress:
For the field E-Mail, I have add a criteria : Is Null
This query is then supposed to give me the list of Owners without e-mail
addresses and the e-mail address of the GM of their hotel
The following script doesn't work !!!!
GmEmailAddress: DLookUp("[Contacts]!","[Contacts]","
[Contacts]![Hotel]='" & [Hotel] & "' And [Contacts]![Contact Type]="GM")
I know that it we have to use ' or " depending of the nature of the field
but I think Ihave been carefull.
I receive a message Syntax error Wrong Operand
Anybody can help me on this,
Would be really greatfull!
I have the following expression in a field I add in the design view of a
query.
Basically I have a table of Contacts named "Contacts" with fields:
Contact Types : GM, Owner or Owner's Rep so it's text
Hotel: name of the hotel so text again, note that each contact is related to
an hotel
E-mail: e-mail address of the person
In a Query I import all the fields and add one called GMEmailAddress:
For the field E-Mail, I have add a criteria : Is Null
This query is then supposed to give me the list of Owners without e-mail
addresses and the e-mail address of the GM of their hotel
The following script doesn't work !!!!
GmEmailAddress: DLookUp("[Contacts]!","[Contacts]","
[Contacts]![Hotel]='" & [Hotel] & "' And [Contacts]![Contact Type]="GM")
I know that it we have to use ' or " depending of the nature of the field
but I think Ihave been carefull.
I receive a message Syntax error Wrong Operand
Anybody can help me on this,
Would be really greatfull!