"OK, so I did this and the combo box shows all of the names now. My query has an ORDER BY clause but it is not ordering by the name, it is showing the names as they are put into the table. Also, when I select a name, the rest of the fields in the form do not change to reflect the information for that person. Is there some kind of event that I need to create to make this work? I have been up for over 24 hours so I am a little foggy this morning, lol."
You will need to go back to your source for the combo box and pick a sort by field. Note that the source can be a hard query, meaning one that is saved and that shows up in your query tab or a dynamic query that shows up only in the source field. Just pick the appropriate place. The jumping to a record is possible and easy, but . . . I don't have access on this computer so I can't look at the code. I am getting ready to go to work. If no one has posted the code by the time I get there, I'll post it. Or you can try this link. http://allenbrowne.com/ser-03.html It has code that goes in the after update event. Here's the code from the link: Sub CboMoveTo_AfterUpdate () Dim rs As DAO.Recordset If Not IsNull(Me.cboMoveTo) Then 'Save before move. If Me.Dirty Then Me.Dirty = False End If 'Search in the clone set. Set rs = Me.RecordsetClone rs.FindFirst "[CustomerID] = " & Me.cboMoveTo If rs.NoMatch Then MsgBox "Not found: filtered?" Else 'Display the found record in the form. Me.Bookmark = rs.Bookmark End If Set rs = Nothing End If End Sub J - Experience hath shewn, that even under the best forms those entrusted with power have, in time, and by slow operations, perverted it into tyranny - Thomas Jefferson on government On Wed, Aug 18, 2010 at 8:02 AM, Bruce Sorge <sor...@gmail.com> wrote: > > OK, so I did this and the combo box shows all of the names now. My > query has an ORDER BY clause but it is not ordering by the name, it is > showing the names as they are put into the table. Also, when I select a > name, the rest of the fields in the form do not change to reflect the > information for that person. Is there some kind of event that I need to > create to make this work? I have been up for over 24 hours so I am a > little foggy this morning, lol. > > Bruce > > On 8/18/2010 5:49 AM, Jerry Barnes wrote: > > "I created a query that selects the user ID adn user name from the table > but > > it only shows me one name in the combo box. I am sure that I am missing a > > setting somewhere." > > > > Do you want the combo to show names but in actuality return the user id? > > > > If so, do the following: > > > > Create your source for the combo. It will probably be a query. The > first > > column should be the user id, the next two column should be first and > last > > name or last name and first name. > > > > Now, in the properties box for the combo box, there will be a field for > the > > number of columns. Choose 3. You want to return all three columns from > the > > query. Then, there should be a property for column widths. Set this to > > 0";1";1". This makes the first column invisible and shows the other two > > columns. In the table behind the form, the user id will be saved. > > > > > > Hope that makes sense. > > > > > > J > > > > - > > > > Experience hath shewn, that even under the best forms those entrusted > with > > power have, in time, and by slow operations, perverted it into tyranny - > > Thomas Jefferson on government > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-community/message.cfm/messageid:325384 Subscription: http://www.houseoffusion.com/groups/cf-community/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-community/unsubscribe.cfm