Results 1 to 3 of 3
  1. #1
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    Alzano Lombardo, Italy
    Posts
    1,483
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Using the Dlookup function in a subform text box (2003)

    I'm trying to use a Dlookup function in the MIL_PREC text box on the subform contained in the startup form of the attached mdb in order to fetch the content of the RAIN field of the CADATI table(which is, in reality, a linked table) but, when I select November 29, 2004(only day available) in the calendar, the MIL_PREC text box displays nothing.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Using the Dlookup function in a subform text box (2003)

    When using a date outside the quotes in a criteria string, it must be enclosed in # characters and it must be in US date format.

    =IIf(IsNull([Giorno]),Null,DLookUp("rain","cadati","[giorno] =#" & Format([giorno],"dd/mm/yyyy") & "#"))

  3. #3
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    Alzano Lombardo, Italy
    Posts
    1,483
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Using the Dlookup function in a subform text box (2003)

    Thank you Hans.

Posting Permissions

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