Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2004
    Posts
    79

    Unanswered: Circular Reference

    I have a form where record source = tblRates. This form has 2 fields from this table (CustNumber and FSCRate). I have a 3rd field that I am trying to look up from another table...

    =DLookUp("[CustName]","tblCustomers","[tblCustomers].[CustNumber]=[tblRates].[CustNumber]")

    I am getting Invalid Countrol Source /Circular Reference error. How can I fix?

  2. #2
    Join Date
    Feb 2004
    Posts
    137
    You may wish to revise the expression to:

    =DLookUp("[CustName]","tblCustomers","[tblCustomers].[CustNumber]='" & [CustNumber] & "'")


    See if this works for you.

  3. #3
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    Eh, that will probably give him a type violation. Assuming CustNumber is a number, don't use the quotes.

    Where does your target customer number come from? The current form? If so, use Reeve's solution sans the quotes:
    =DLookUp("[CustName]","tblCustomers","[tblCustomers].[CustNumber]=" & [CustNumber])

    Basically what he was trying to show you was the & value & part. That pulls the value in from the form instead of passing it as a literal string.
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •