Linking a Field to another Field

  • Thread starter Thread starter ScS
  • Start date Start date
S

ScS

How would I go about linking one field to another?

ex:In one field I have the numbers 5276
I want to link that field to another so that it
automatically enters in another field.
ex:When I enter 5276, in another field, I want it to
automatically enter in 45

ScS
 
How many possible number relationships are you talking about? Just one,
five, five hundred?

The easiest and if you are only dealing with 5276, then use code against
that fields After Update event
Thus something like this:
If me.fieldnamewith5276 =5276 then
me.fieldnameto45 = 45
Else
me.fieldnameto45 = 0 <-- This could also say Null
End If

If the values are text based then quotes must encapsulate the "5276" and
"45"

If you are dealing with a mass amount of numbers then use DLookup against a
table that shows the 4 number relationship to the 2 number relationship. The
DLookup will be set against the field containing the 2 digit value.
 
Back
Top