Hey I am trying to store some values in a hashmap to put into a customized view.
the problem is when assigning keys in the put method of my hashmap I get an error when I try to get the key from a variable within an object that is withing my other object
here is my code:
ListView lv= (ListView)findViewById(R.id.listView1);
String[] from = new String[] {"fornavn", "starttid", "sluttid"};
int[] to = new int[] { R.id.Kunde, R.id.StartTime, R.id.EndTime };
List<HashMap<String, String>> fillMaps = new ArrayList<HashMap<String, String>>();
for(Appointment a : todayList) {
HashMap<String, String> map = new HashMap<String, String>();
//here is my error I don't know what to put as key??
map.put("kunde.fornavn", "col_1_item_" + a.kunde.fornavn);
map.put("starttid", "col_2_item_" + String.valueOf(a.startTime));
map.put("sluttid", "col_3_item_" + String.valueOf(a.endTime));
fillMaps.add(map);
}
SimpleAdapter adapter = new SimpleAdapter(this, fillMaps, R.layout.row, from, to);
lv.setAdapter(adapter);
logCat:

It would seem that
is null