Results 1 to 6 of 6
  1. #1
    vCallNSPF is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Dec 2009
    Posts
    49

    Search by field

    I have a form for Pagers that has two search functions:

    The first is a 'Search by Serial No.', which allows me to enter in a serial number and it comes up with that pager. It works fine and I have no problem with it.

    The other search is 'Search by Facility', where there may be more than one Pager in each of my companies buildings. This is what I'm having a problem with.

    The way my form is set out is with a data entry form up the top, and a sub-form down the bottom (that looks like a table) where I want to have other Pagers from the same facility displayed. How do I get the other Pagers from the same facility to appear in the sub-form?

  2. #2
    HiTechCoach's Avatar
    HiTechCoach is offline MS MVP - Access Expert
    Windows 7 Access 2010 (version 14.0)
    Join Date
    Jul 2010
    Location
    Oklahoma, USA
    Posts
    702
    Try setting the Master/Child linking field properties for the sub form control.

    You will probably need to use the after update event of the control for the Facility to requery the sub form.

  3. #3
    vCallNSPF is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Dec 2009
    Posts
    49
    Quote Originally Posted by HiTechCoach View Post
    Try setting the Master/Child linking field properties for the sub form control.

    You will probably need to use the after update event of the control for the Facility to requery the sub form.
    Hey,

    I've set the master/child linking field, how do I use the after update event to requery?

    EDIT: It DOES actually show all the results for a facility BUT I have to press the arrows down the bottom of the subform, is there any way to stack them there like a table?

  4. #4
    HiTechCoach's Avatar
    HiTechCoach is offline MS MVP - Access Expert
    Windows 7 Access 2010 (version 14.0)
    Join Date
    Jul 2010
    Location
    Oklahoma, USA
    Posts
    702

    Arrow

    I am assuming you are using a comb box to validate the user input

    To requery the sub form from the combo box place this code in the After Update event:

    Code:
     
    Me.YouSubFormNameHere.form.Requery
    Note: substitute YouSubFormNameHere with your actual sub form's control name.


    Change the sub form to continuous view to see all the records in a list.

  5. #5
    vCallNSPF is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Dec 2009
    Posts
    49
    Quote Originally Posted by HiTechCoach View Post
    Change the sub form to continuous view to see all the records in a list.
    this is just what i needed Solved

  6. #6
    HiTechCoach's Avatar
    HiTechCoach is offline MS MVP - Access Expert
    Windows 7 Access 2010 (version 14.0)
    Join Date
    Jul 2010
    Location
    Oklahoma, USA
    Posts
    702
    Quote Originally Posted by vCallNSPF View Post
    this is just what i needed Solved
    Glad that worked for you.

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

Similar Threads

  1. Replies: 2
    Last Post: 08-31-2010, 08:57 PM
  2. Search a Number in Database Field
    By julia_877 in forum Programming
    Replies: 3
    Last Post: 08-06-2010, 01:24 PM
  3. Creating a Search Field
    By SKUPenn in forum Programming
    Replies: 1
    Last Post: 01-28-2010, 08:39 PM
  4. Search any field and part thereof
    By Johan in forum Forms
    Replies: 0
    Last Post: 09-03-2008, 08:01 AM
  5. Search All Field
    By robbiebrown34 in forum Access
    Replies: 0
    Last Post: 05-17-2007, 09: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