Click to See Complete Forum and Search --> : Sort record
I have a database through Access that holds name's and addresses. There are duplicate names so the primary key is the generic counter. My question is how can i sort that database from VB6 to where all the names are in order and when using the data controlit scrolls in alphabetical order... Thanks..
vikram.k
Jun 28th, 1999, 11:26 AM
Hi Wookie,
For example, your table is address_detail and fields are name,state,... Then you have to declare the following statement in form_load even if you are using Data Control.
Private Sub Form_Load()
Data1.RecordSource = "select * from address_detail order by name"
End Sub
Now you will get what you have expected at the time of execution.
Bye!.
Thanks!!!
So what do i put on the right of the =
data1.recordsource = State from address_detail order by name. ???
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.