Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Sort the ArrayList by specific object  RSS feed

 
Fred Schaefer
Greenhorn
Posts: 4
Firefox Browser Netbeans IDE Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to sort my arrayList by the Lname. It outputs the first two entries and then gives me an error. I'm not sure if I'm setting up the Collections.sort / Comparator correctly. The second issues I'm trying to fix is that I want certain parts of my output to be bold. I put in the html code but all it does is display the code. (output): "<b>First name = </b>" instead of First Name =

 
Knute Snortum
Sheriff
Posts: 4073
112
Chrome Eclipse IDE Java Postgres Database VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is the full text of the error?
 
Campbell Ritchie
Marshal
Posts: 55681
161
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You also have an error which you haven't seen in line 19.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!