Results 1 to 3 of 3
  1. #1
    netguy is offline Novice
    Windows 8 Access 2007
    Join Date
    Sep 2014
    Posts
    16

    DLookUp help!!

    Folks I have read a many different ways to set a default value in a Txt box using DLookUp function. Most of the examples do not show by running against a query . here is my example which does not work.

    My saved query (qry_num_prac_no_regions)


    SELECT COUNT(tbl_Practices.PRAC_NAME) AS [Practices w/no Region]
    FROM tbl_Practices
    WHERE (((tbl_Practices.REG_ID) Is Null));

    Default value on txt box:




    =DLookUp("[Practices w/no Region]","qry_num_prac_no_regions")

    I do not have a third parameter set however when I refresh the form I get infamous #Name?

    Not sure what I'm doing wrong.

  2. #2
    qa12dx is offline Competent Performer
    Windows 7 64bit Access 2007
    Join Date
    Nov 2012
    Location
    india
    Posts
    112
    =DLookUp("Practices w/no Region","qry_num_prac_no_regions")

  3. #3
    netguy is offline Novice
    Windows 8 Access 2007
    Join Date
    Sep 2014
    Posts
    16
    The problem I was having is that I was entering this into the default value of the txt field. Instead in needed to go into the Control Source field

    Thank you!

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

Similar Threads

  1. Need help with a DLookup using Or
    By jax1000rr in forum Queries
    Replies: 1
    Last Post: 05-06-2013, 11:18 AM
  2. Should I be using Dlookup
    By parishpete in forum Programming
    Replies: 6
    Last Post: 11-08-2012, 05:39 AM
  3. Dlookup
    By imtiaz703 in forum Forms
    Replies: 1
    Last Post: 03-20-2012, 11:03 AM
  4. Dlookup
    By Wombat in forum Forms
    Replies: 2
    Last Post: 03-03-2012, 07:21 PM
  5. dlookup help
    By gsantacruz in forum Programming
    Replies: 9
    Last Post: 10-11-2010, 11:46 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