Results 1 to 6 of 6
  1. #1
    5 Star Lounger
    Join Date
    Jul 2001
    Location
    NJ, USA
    Posts
    617
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Subform not working (Access03)

    I have a main form with a tab control. On one page of the control I have a subform connected to the main from by the EmployeeID. That one works as
    expected. On another page I have put a second subform that has a subsubfrom on it. I can not get it to work for some reason. Trying to troubleshooting
    the situation I removed the subsubform. That didn't help. I have reattached the subform several times. Does anyone have any other ideas?

    Main form named frmEmployees and is tied to the qryEmployees (PK = EmployeeID) There is a Tab control on frmEmployees. On the first page I have subfrmProLic based on the qryProLic. The subfrmProLic is tied to the frmEmployees by the EmployeeID. This subfrm works correctly with the main form. On another page of the tab control I have subfrmIncidents again linked by EmployeeID to the main form. On the subfrmIncidents there is a sub form called subfrmIncidentCost this is tied to the subfrmIncidents by the EmployeeID and IncidentID. I can't figure out why the Incident forms don't work. Thanks for any and all thoughts.

    Fay

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

    Re: Subform not working (Access03)

    You have explained the setup, but there is not enough information to draw any conclusions. Could you post a stripped down version of the database?
    <UL><LI>Make a copy of the database and work with that.
    <LI>Remove all database objects (tables, queries, forms, reports, macros and modules) that are not relevant to the problem.
    <LI>In the remaining table(s), remove most records - leave only the minimum number necessary to demonstrate the problem.
    <LI>Remove or modify data of a confidential nature.
    <LI>Do a compact and repair (Tools/Database Utilities).
    <LI>Make a zip file containing the database; it should be below 100KB.
    <LI>If you have difficulties getting the zip file below 100 KB, save the database in Access 97 format and then zip it. (Of course, this only helps if you're using Access 2000 or later.)
    <LI>Attach the zip file to a reply.[/list]That would enable Loungers to take a look at it directly.

  3. #3
    5 Star Lounger
    Join Date
    Jul 2001
    Location
    NJ, USA
    Posts
    617
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Subform not working (Access03)

    Here is a stripped version of the file. I also started having problems last night in that the subfrmIncidentCosts form is only displaying one record when there should be two records on the employee 006 and 007. Thank you for looking at this.

    Fay
    Attached Files Attached Files

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

    Re: Subform not working (Access03)

    There are several problems:
    - You haven't created relationships between the tables, hence there is no referential integrity. So you haven't noticed that:
    - The input mask for EmployeeID in tblEmployees is different from that in tblIncidents, causing the stored values to be different.
    - EmployeeID is superfluous in tblIncidentCosts; IncidentID defines the incident and hence the employee.
    See attached version (modified!)
    Attached Files Attached Files

  5. #5
    5 Star Lounger
    Join Date
    Jul 2001
    Location
    NJ, USA
    Posts
    617
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Subform not working (Access03)

    Thank you Hans for your help. I didn't catch that the EmployeeID didn't match across tables even though there was a input mask. Is there a good book on how to troubleshoot problems. Fay

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

    Re: Subform not working (Access03)

    Try a Google search for troubleshoot access database or something similar. I don't have specific recommendations.

Posting Permissions

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