I have added a button in expandable list view header. On clicking the button I need to pass a value from adapter to activity.
Asked
Active
Viewed 870 times
0

Sridhar T Saminathan
- 210
- 1
- 3
- 11
-
where is expandable listview and button? I can't see. – Rustam Sep 16 '15 at 07:45
-
http://stackoverflow.com/questions/17417839/how-to-pass-values-from-adapter-to-activity – Amarjit Sep 16 '15 at 07:46
-
i tried this sample, on clicking the button i need to pass the value from adapter to activity – Sridhar T Saminathan Sep 18 '15 at 07:04
-
i have achieved by adding an interface -- Thanks for Help – Sridhar T Saminathan Jun 21 '17 at 05:42
1 Answers
0
You can add listener or simply use ((YourActivity)mContext).setMyValue();
The mContext
is the context from your adapter constructor.

Kyryl Zotov
- 1,788
- 5
- 24
- 44
-
i am doing in Xamarin Android can you please share the link – Sridhar T Saminathan Sep 16 '15 at 08:25
-
-