search

Home  >  Q&A  >  body text

android - RecyclerView删除数据项后执行下拉刷新报空指针

在RecyclerView中删除一行后下拉刷新,会报空指针错误。
![图片描述][1]
PHP中文网PHP中文网2772 days ago664

reply all(2)I'll reply

  • PHP中文网

    PHP中文网2017-04-17 17:28:50

    If you only delete the option but do not remove the data in the list, an error will occur when loading again. There may be many situations, but the conditions you gave are too few

    reply
    0
  • PHPz

    PHPz2017-04-17 17:28:50

    Check to see if after deleting a row, you did not destroy the total data of the data source or see if there is any problem with the function callnotifyDataSetChanged

    reply
    0
  • Cancelreply