Results 1 to 4 of 4
  1. #1
    brharrii's Avatar
    brharrii is offline Advanced Beginner
    Windows XP Access 2010 64bit
    Join Date
    Jun 2012
    Location
    Seattle, WA
    Posts
    63

    Dlookup issue

    I'm assuming this is the correct place for this, if it isn't I apologize, let me know and I can find another place to post it, thanks!

    I'm working in access 2010, I have 2 tables:

    tblProductinfo
    - itemNumber (PK)


    - JDEDescription
    - Sauce (Cbox from tbl Sauce)
    and

    tblSauce
    - SauceID
    - Sauce (populates cbox options for sauce field in tblProductinfo also FK)
    - Ingredients (Memo field 255+ characters)
    Form looks like this:

    ProductInfo
    - ItemNumber
    - JDEDescription
    - Sauce (cbox populated with options from tblSauce.sauce recorded in tblProductinfo.sauce)
    - SauceID (unbound textbox, using dlookup to find corresponding tblsauce.SauceID)
    - SauceIng (unbound textbox, using dlookup to find corresponding tbl.ingredients)
    For the ubTextbox: SauceIng, I am using the following dlookup:

    Code:
    =DLookUp("ingredients","tblSauce","Sauce = " & Nz([sauce],0))
    The field keeps returning the same: #Error and not displaying the ingredients I have listed in tblsauce.Ingredients (this is a memo field, I don't know if that could be causing a problem?)

    Does anyone have any suggestions on what I may have done wrong? Thanks!

  2. #2
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    The first thing I would suggest is fix your tables. Get rid of the look-up fields. See http://access.mvps.org/access/lookupfields.htm

    Set up a relationship between the two tables. Then you can fix the controls. Why are you using unbound controls???

    The text box is the only control that I know of that will display a memo field.

  3. #3
    brharrii's Avatar
    brharrii is offline Advanced Beginner
    Windows XP Access 2010 64bit
    Join Date
    Jun 2012
    Location
    Seattle, WA
    Posts
    63
    ssanfu I could kiss you,

    This has been a week of mass frustration over this issue and it was just resolved with the help of your advice.... Thank you.

  4. #4
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    (awwww shucks... )

    Glad to be of help....

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Dlookup annoying issue
    By Lupson2011 in forum Forms
    Replies: 8
    Last Post: 02-14-2012, 08:28 AM
  2. DLookup issue
    By seth1685 in forum Programming
    Replies: 5
    Last Post: 01-12-2012, 08:55 AM
  3. Easy DLookup Issue
    By Niki in forum Access
    Replies: 7
    Last Post: 05-25-2011, 03:00 PM
  4. Tough form issue that uses DLookup's
    By Solola in forum Forms
    Replies: 3
    Last Post: 03-15-2011, 01:25 PM
  5. Dlookup
    By janjan_376 in forum Access
    Replies: 20
    Last Post: 07-07-2009, 07:40 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums