Results 1 to 3 of 3
  1. #1
    Lou_Reed is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2015
    Posts
    1,664

    A form and a sub form

    I am trying to coordinate two forms that both add an employee to a database. That may
    sound easy, but there are a lot of other things involved.

    The first form has a button to open up the second form.

    And, there is the trouble. One must go from one form to the other typing a name on the first form
    and clicking to open the second form with additional tasks including adding the name to the database
    and adding info about the name such items as employee background.

    I can see why there are two forms, but it make things awkward going from one form to the other opening one form
    and then closing it, while simultaneously opening the other second form.



    Then you get to new employee and must start the whole process over again with the first form, then the second form and so on.

    There must be a better way.

    This is what I want to do and I need feedback on whether it is possible or not.

    Open the first form and type in the employees name and related info, then open the second form, but make the first form
    that was opened previously now a sub form on the second form. The first form does dual duty as a form and as a sub form.

    Thus my first form has a dual identity. It is at one time a form and at another time a sub form to another form.

    I am not sure if this is possible.Also, please note that the first form is much smaller than the second form so it could be used
    as a sub form.

    If there is an easier way to do this then I am open to suggestions. My questions is can a form do dual duty as a form
    and a sub form in the same database?

    Any help appreciated. Thanks in advance.

    Respectfully,

    Lou Reed

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    you dont need 2 forms. you can have 1 form that connects to tEmployee table.
    here you can add employee names all day long and never leave the form.
    this 1 form is the parent/child sub form.
    you can enter the employee name, SAVE, then enter the details all in the 1 form.
    you MUST save the parent form data, in order to enter the sub form data.
    you could , on NEW RECORD event, hide the sub form , then when user clicks a SAVE RECORD button, it would make the subform visible. (to prevent errors of not saving the parent name)

  3. #3
    Lou_Reed is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2015
    Posts
    1,664
    It seems that what you say is one correct way. However, I inherited this project with the two separate forms.

    Can you provide a link to discuss more about the parent/child sub form?

    Any help appreciated. Thanks in advance.

    Respectfully,

    Lou Reed

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

Similar Threads

  1. Replies: 3
    Last Post: 01-05-2016, 12:25 PM
  2. Replies: 1
    Last Post: 11-18-2014, 12:35 PM
  3. Replies: 0
    Last Post: 06-03-2014, 05:15 AM
  4. Replies: 6
    Last Post: 09-02-2012, 04:30 PM
  5. Replies: 9
    Last Post: 02-15-2011, 03:05 PM

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