Update View with updated data in Android -
i noob in android. suppose have 2 activity in android app.
activity , b, on activity on click on 1 button activity b. here activity b want update view updated data in activity a. got updated data in activity b should use here localbroadcastreceiver or ?? when press app should show me updated data in activity a
should use our custom callback here update ui view data of activity activity b ??
no, shouldn't use broadcastreceiver that. method depends on size of data want transfer activity b activity a. if it's quite small, can start activity b startactivityforresult , data @ onactivityresult method (in activity b should use setresult once done). if size of data quite big, it's better use db storing instead of keeping in memory.
Comments
Post a Comment