Note that there are some explanatory texts on larger screens.

plurals
  1. POhow to add notifyDataSetChanged method in base adapter
    primarykey
    data
    text
    <p>how to update <code>GridView</code> in my code when i used this code <code>cla.notifyDataSetChanged</code>; is say cannot resolve how to add <code>notifyDataSetChanged</code> method in my adapter class? please help me what do u do? my adapter class not have <code>notifyDataSetChange</code> method</p> <pre><code>public class fifthscreen extends Activity { private AQuery androidAQuery; CategoryListAdapter3 cla; androidAQuery = new AQuery(this); static ArrayList&lt;String&gt; Category_name = new ArrayList&lt;String&gt;(); static ArrayList&lt;String&gt; Category_image = new ArrayList&lt;String&gt;(); cla = new CategoryListAdapter3(fifthscreen.this); gidView.setAdapter(cla); </code></pre> <p>Adapter Class</p> <pre><code>public class CategoryListAdapter3 extends BaseAdapter { private Activity activity; private AQuery androidAQuery; public CategoryListAdapter3(Activity act) { this.activity = act; // imageLoader = new ImageLoader(act); } public int getCount() { // TODO Auto-generated method stub return fifthscreen.Category_ID.size(); } public Object getItem(int position) { // TODO Auto-generated method stub return position; } public long getItemId(int position) { // TODO Auto-generated method stub return position; } public View getView(int position, View convertView, ViewGroup parent) { // TODO Auto-generated method stub ViewHolder holder; androidAQuery = new AQuery(getcontext()); if(convertView == null){ LayoutInflater inflater = (LayoutInflater) activity .getSystemService(Context.LAYOUT_INFLATER_SERVICE); convertView = inflater.inflate(R.layout.viewitem2, null); holder = new ViewHolder(); convertView.setTag(holder); }else{ holder = (ViewHolder) convertView.getTag(); } holder.txtText = (TextView) convertView.findViewById(R.id.title2); holder.imgThumb = (ImageView) convertView.findViewById(R.id.image2); holder.txtText.setText(fifthscreen.Category_name.get(position)); androidAQuery.id(holder.imgThumb).image(fifthscreen.Category_image.get(position), true,true); return convertView; } private Activity getcontext() { // TODO Auto-generated method stub return null; } static class ViewHolder { TextView txtText; ImageView imgThumb; } } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload