using notifyItemRemoved or notifyDataSetChanged with RecyclerView in Android
Use notifyItemRangeChanged(position, getItemCount()); after notifyItemRemoved(position); You don’t need to use index, just use position. See code below. private List<DetectedIssue> issues = new ArrayList<DetectedIssue>(); @Override public void onBindViewHolder(RecyclerView.ViewHolder holder, int position) { // – get element from your dataset at this position // – replace the contents of the view with that element if(position >0){ RiskViewHolder … Read more