AccessDiscussion of Microsoft Access database design and programming. See also the forums for Access ASP and Access VBA.
Welcome to the p2p.wrox.com Forums.
You are currently viewing the Access section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
I have a main form with a tab control. On various tabs I have included a number of different subforms all connected to the main page via the TractID.
I would like the user to be able to enter data and view data from these subforms. For example, if they are viewing Tract Number 1, then all the subforms will show data pertaining to Tract Number 1.
The problem I am currently experiencing is that if the underlying tables which the subforms are based upon do not have any data for a tract then the subforms do not show up at all. When you view the main page and click on the tab to enter data into the subform there is just a big white box. None of the fields, labels or formatting for the subform are visible. I'm at a complete loss.
I did not use VBA to create the main form and subforms... I used the old fashion way of creating the main form and subform using the wizard.
Welcome, BJ
Please post a bit more information:
A few things to check:
1) Is the form Read-only? If so, that is Access's behavior with unpopulated subforms.
2) Check the property sheet to confirm that the LinkChild and LinkParent fields have your key (tractID).
3) If the subform recordset is based on a query, is TractID the FIRST field in the query? (If not, change it so that it is and see if that takes care of your problems.)
4) And of course........What is the relationship between the recordset for the main form and the subforms? (It should be 1:many with the 1 side being on the main form and the many side on the subform).
Ok so I'm just a tad bit embarrassed that the solution was so dang easy. I simply had to change the properties to Allow Additions, Edits, Deletions, etc.