[RESOLVED] Access excluding repeats in combo boxes
This is probably something really easy that I'm just overlooking, but, in a form that I have there are combo boxes that are populated by previously used answers, and each time an answer is used it gets added to the combo box, so the next time you go to enter something, it will say the same thing 2 times, and so on and so on. Is there a way to have access exclude these from the combo box, without removing their entrys from the list? Thanks in advance!
Re: Access excluding repeats in combo boxes
Re: Access excluding repeats in combo boxes
this "correct" answer assumes you are populating the combobox choices from an underlying table or query(which you should be doing)
Try editing the sql that populates the combo box directly in the rowsource property. It should say something like this:
Select xx from xx where etc etc etc
Change it to this:
Select Distinct from xx where etc etc etc
The "Distinct" keyword is what is needed here. It tells the sql server ignore duplicates.
Re: Access excluding repeats in combo boxes
THANK YOU!!!! worked perfectly!
Re: [RESOLVED] Access excluding repeats in combo boxes
the best thanks is a vote! :D Unfortunately they don't count unless you have 20 posts or more, mr. 19 posts, But i was glad to help anyway.