Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sorting a DataSet
Message
De
23/10/2003 12:46:05
 
 
À
23/10/2003 12:33:10
Information générale
Forum:
ASP.NET
Catégorie:
Bases de données
Divers
Thread ID:
00841585
Message ID:
00841669
Vues:
23
After having converted the rest of my code to take care of reading from the view instead of the DataSet, I face the situation that even after the view has been sorted that the display is not sorted at all but simply in the same order as the DataSet.

Here's the code:
' Get it into a view
Dim loView As DataView
loView = loData.Tables("Temp").DefaultView

' Sort it
loView.Sort = "StartDate"

' Display the user group meetings
lcHtml = ""

For lnCompteur = 0 To loView.Count - 1 Step lnCompteur + 1
   ldDate = loView.Table.Rows(lnCompteur)("StartDate")

   lcHtml = lcHtml + "<B><A HREF=" + loView.Table.Rows(lnCompteur)("Url") + ">" + _
    loView.Table.Rows(lnCompteur)("Title") + "</A></B>"
   lcHtml = lcHtml + " "
   lcHtml = lcHtml + "<FONT COLOR=GREEN>" + ldDate.ToString("MMMM dd, yyyy") + "</FONT>"
   lcHtml = lcHtml + "<BR>"
   lcHtml = lcHtml + loView.Table.Rows(lnCompteur)("Message")
   lcHtml = lcHtml + "<P>"
Next
ConferenceVFP.Text = lcHtml
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform