I am creating a webpage which is using asp .net as its backend. I need to grab categories from my database which is SQL Server. I am using this code right now
For Each row00 As DataRow In f_oDatatable(7).Rows
sCategories += row00.Item("Category").ToString & " / "
Next
If sCategories.Length > 0 Then
sCategories = sCategories.Substring(0, sCategories.LastIndexOf(" / "))
CType(Me.FindControl("dbcategories"), HtmlGenericControl).InnerHtml = "Categories: " & sCategories
This code works great and outputs my categories correctly. But what I need to do is have the categories output randomly. (i.e: "one/ two/ three/ four/ five" - and then another time - "two/ five/ one/ three/ four")
I can not have it create a random string in the database b/c of other dependencies for the categories to be the same every time.
Any help would be greatly appreciated. Thank you