Avatar of SteveL13
Flag for United States of America

asked on 

How limit list selections if record is not a new record

On a form I have a single select listbox.  The SQL behind the listbox is:

SELECT tblLoadsHeader.LoadRecordID, tblLoadsHeader.ContractNumber
FROM tblLoadsHeader
ORDER BY tblLoadsHeader.[ContractNumber];

Which display all ContractNumbers in tblLoadsHeader.

This is fine for a new record.  But If I'm viewing an existing record I only want to see the ContractNumber in the listbox that was selected when the record was created.  Note:  The contractnumber IS being stored in the table that is the record source for the form.

How can I make the listbox only show that record?
Microsoft Access

Avatar of undefined
Last Comment

8/22/2022 - Mon