Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sort in Recordset
Message
De
10/10/2000 10:51:51
 
 
À
03/10/2000 05:12:23
Information générale
Forum:
Visual Basic
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00423328
Message ID:
00427288
Vues:
16
>>>How can I Sort and change the Sort field in an ADO RecordSet?
>>
>>Do you mean once the recordset is opened? In this case use this syntax:
>>
rst.Sort = "YouFieldName"
>
>Thanks Eric.
>Yes, the RecordSet is already Opened with multiple fields returned.
>
>Need another advise. If I changed the Sort order on another field name
>in the RecordSet, I don't seems to be able to use locate a record by
>
>rst.Find "FName LIKE '" & strName & "'"
>
>Anything wrong with my code? Pls advise, thanks.


I don't know if this is still necessary, but you can sort your data when you open your RecordSet.
rst.Open "SELECT * FROM database ORDER BY FName"

I also use the Find command and it works fine.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform