Consulting

Results 1 to 3 of 3

Thread: Dlookup and vba code request

  1. #1
    VBAX Newbie
    Joined
    Nov 2022
    Posts
    1
    Location

    Dlookup and vba code request

    I have a table named frmNew with 3 fields; CustomerNo, Except and Status.
    The status can either be open or closed.


    I have a form named, frmNew with 3 text boxes of txtCusNo, Except.


    I want a vba code (preferrably, with Dlookup) that will look up the CustomerNo on the table anytime a customer number is specified in the txtCusNo and if the status is open, it should show a messagebox of "I like this".

  2. #2
    VBAX Mentor
    Joined
    Nov 2022
    Location
    The Great Land
    Posts
    331
    Location
    Why would you need DLookup if form is bound to table? Is this form used for data entry of customers?

    If you want to provide db for analysis, follow instructions at bottom of my post.
    How to attach file: Reading and Posting Messages (vbaexpress.com), click Go Advanced below post edit window. To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    VBAX Regular
    Joined
    Nov 2020
    Location
    Swansea,South Wales,UK
    Posts
    90
    Location
    I am sure this is a crosspost, but unable to find the other post in whatever forum I saw it previously.
    I am sure I responded to that post as well.

    Found it! https://www.access-programmers.co.uk...lookup.325593/

Tags for this Thread

Posting Permissions

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