How to send a data with the "setResult" of a non-activity to an activity?

0

I have a class with a dialog that is not an activity and the result of this dialog needs updating in the activity. To do this I'm passing the Activity via constructor to the dialog, but it did not work. Does anyone know how and if it's possible to do this? Thank you in advance.

My attempt: act.setResult(Activity.RESULT_OK);

Actually I do not even need to send a data to Activity, because I retrieve the data in Activity via bank, what I need is just to know if I clicked on a dialog button to get the database data in my Activity.

    
asked by anonymous 29.03.2016 / 17:09

0 answers