Unbound listbox

H

Harmannus

Hallo,

Is have a form with a unbound list box and sort options. I want to "connect"
the sort options to the sort order of the unbound listbox.

Is use: CP = Contactperson

Forms![frmCP].CPList.OrderBy = "qselCPList.Lastname"
Me.CPList.Requery

But i get a error message.

How do i address the unbound listbox CPlist correctly in the above
statement?

Thanx for any tips.


Regards,

Harmannus

---- Full code ---

Me.Requery
Select Case Sorteren.Value
Case "1"
Forms![frmCP].OrderBy = "tblCP.Lastname"
Forms![frmCP].CPList.OrderBy = "qselCPList.Lastname"
Me.CPList.Requery
Case "2"
Forms![frmCP].OrderBy = "tblCP.Firstname"
Case "3"
Forms![frmCP].OrderBy = "tblCP.OrganizationID"
End Select
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top