Microsoft Access Forms With Combo List

How can I create a display only form in MS Access to display all the rows in a table, with one of the fields being a combo box so the result would be:

PartNo - Description - Products(Combo)

For the Products(Combo), I wanted to specify the source as an SQL Query that displays all the Products associated with the PartNo (in that row)
I would need to refer to the field in that particular row somehow in the SQL statement but I cant work out how to specify it.

Anyone know the best way to achieve this ?
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Can you give us a couple of sample rows from your table?

ls21gceAuthor Commented:
Hi Calpurnia,

Please See the two tables attached.

I want to see only 1 line of output for each record which includes the comb list of Product_Code/Qty
I'm assuming your form will be displayed in 'Continuous forms' view.

The first thought that comes to mind is to set the Row Source for the Combo box in the 'On current' event of the form.

Then you'd be looking at something like:

Private Sub Form_Current()
    Dim strSQL As String
    strSQL = "SELECT * FROM Products WHERE [Number]=" & Me!Number
    Me.Combo1.RowSource = strSQL
End Sub

You'll need to change 'Combo1' to the name of your combo box.

Could I also suggest that you don't use 'Name', 'Number' and 'Date' as field names - they can cause problems. Field names like 'ClientName' or 'ProductNumber' are fine. It's also good practice to avoid spaces in field names.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
ls21gceAuthor Commented:
Hi Calpurnia,
Great thanks, the solution using Me! works perfectly just what I needed.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.