I am fetching JSON Data from server and able to parse JSON Data by code. now storing it in hashmap and then adding to arraylist and displaying in listview everything seems working fine.
HashMap<String, String> map = new HashMap<String, String>();
map.put(Constants.KEY_REFERENCE,p.reference); map.put(Constants.KEY_NAME, p.name);
map.put("distance","p.distance");
ArrayListItems.add(map);
Now,When i display the data in listview it works fine ,but now i want to sort the distance in ascending order ,with least starting from top . Any help will be appreciated .Thanks in advance
now i am able to sort but there is something wrong with the distance when i display it shows 1.23, 1.45, 2.39, 3.56, and then it shows 0.38, 0.56.
Its not sorting for values starting with 0
So please help me.