View Full Version : Adding a field to a form at runtime


Anthony Strickland
11-15-2001, 04:04 AM
I have created a Bill of Lading form for our factories shipping department based on a query and a table. The query gives me the customers info and the table is the subdata for each line item within the Bill of Laden. It works great, however the shipping manager wants me to put a COMMENTS field in the parent portion of the form. I went to the table that the parent query is based on a inserted a field called Shipping Comments and than I went to the query and inserted it as a viewable field. I than opened my existing form and viewed the field list, but it does not appear as a field that I can drag into this form. WHY?

DJN
11-15-2001, 06:45 AM
When you say opened the form, you do mean in design view? The only other thing I can think of is that the Show check box has not been ticked. Just a thought.


David

Pat Hartman
11-15-2001, 06:34 PM
You need to force Access to re-build the form's field collection. To do this, delete the recordsource, save the form, then add the query name back to the recordsource. This same problem occurs with reports. When the recordsource is a query, Access needs to be forced to re-build the form/report's field collection if the query is changed.