android - Syntax error with Toast -


list<listitem> items = new arraylist<listitem>(); . . . . protected void onlistitemclick(listview l, view v, int position, long id)  {      //super.onlistitemclick(l, v, position, id);     toast.maketext(listpage.this, items[position].sid, toast.length_short).show(); } 

getting error toast, error says "type of expression must array type resolved list[listitems]." need know wat correct way of writing toast is

replace

items[position].sid 

by

items.get(position).sid //assuming sid type of string 

Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -