You need to sign in to do that
Don't have an account?
Ordering a List of Custom Object Records
Hello Friends,
I have a query regarding ordering of a custom List having Custom Object records!
In this scenario, I cannot use Order-By as I am not populating this list directly from a SOQL query. Also, I am sure, we can write custom logic for ordering a custom list, but I was just thiking if I can avoid writing custom code.
But the thing, I am not sure is, how a "DataList" component works. I read the docs which say that it can be ordered or un-ordered, but I am unable to follow it completely considering my scenario.
What if, my list is having 5 fields per custom obejct record, then how does the datalist arrange the data based on a specific field, say Name?
Can someone please clarify this? Also, what is the best approach/solution in such a case?
Many Thanks,
Cool_D
I believe that the ordered/unordered here refers to the type of HTML list tags that will be generated. An ordered list is enclosed in <ol> tags and will add cardinality, so the list will appear as :
1. Item 1
2. Item 2
etc
While an unordered list will be enclosed in <ul> tags and display as:
o Item 1
o Item2
[edited as submitting from chrome removed the vital list formatting!]
All Answers
I believe that the ordered/unordered here refers to the type of HTML list tags that will be generated. An ordered list is enclosed in <ol> tags and will add cardinality, so the list will appear as :
1. Item 1
2. Item 2
etc
While an unordered list will be enclosed in <ul> tags and display as:
o Item 1
o Item2
[edited as submitting from chrome removed the vital list formatting!]
Thanks so very much Bob for the elaborate and informative answer;)
That surely, clarifies my issues!
I will try the custom logic you have mentioned and see, if I can do something similar. It does'nt seem to be too complex at the face of it :)
Thanks Again!!
Cool_D