Home > Software engineering >  How to reflesh RecycleView on Fragment after dismiss() DialogFragment?
How to reflesh RecycleView on Fragment after dismiss() DialogFragment?

Time:12-03

Could you tell me the way to refresh data on RecycleView on Fragment. On DialogFragment, there are some TextInputEditText, and users could change the data. After users closed DialogFragment with dismiss(), RecycleView isn't changed.

Tried to use Intetnt back to RecycleView, but I think it is not correct way. My environment is JAVA, Android Studio.

CodePudding user response:

You can use StartActivityForResult, it is the best way to get you modified data, here's a link to documentation and how to integrated it enter link description here

CodePudding user response:

You must notify all reorganized observer that the data set is altered to get visual effects using notifyDataSetChanged().More details on notifyDataSetChanged()

This link also shows the use of notifyDataSetChanged()

  • Related