Compare the text field to table field

Gemma Khan

Registered User.
Local time
Today, 13:21
Joined
Jun 29, 2009
Messages
13
Hi,
How to compare the text field to Table fields? :confused:

Thanks
 
The text field on the form can be referred to by its name.
From the form's Class Module:

Me!controlname

Use a Domain Lookup for the table field.

Code:
DLookUp("wantedfieldname","tablename","somefield.tablename=Forms!formname.somecontrolname")
 
If you need to compare text field on form to some current record field, you can reach them by their names.

Lets assume you have:

  • Table1 with (ID,Full Name) fields
  • form tied to Table1, but without the textbox bound to Full Name field
  • unbound textbox named Txt
You can write something like this:
Code:
If [COLOR=RoyalBlue]Txt[/COLOR]=[COLOR=RoyalBlue]Full_Name[/COLOR] Then la-la-la...
 

Users who are viewing this thread

Back
Top Bottom