Hi,
List
t.Add(new MyClass() { name = "Bob", age = 36, country = "Spain" });
...
t.Sort();
This doesn' work. How can i do that? Can i sort according any field?
Thanks
V.
Hi,
List
t.Add(new MyClass() { name = "Bob", age = 36, country = "Spain" });
...
t.Sort();
This doesn' work. How can i do that? Can i sort according any field?
Thanks
V.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Jaydeep PatilRank #205 · 11.7K reputationPosted Aug 20, 2022, 12:25 AM EDT
If you want to sort using some class field then try thisValerie MeunierRank #1,526 · 1K reputationPosted Aug 21, 2022, 5:00 AM EDT