i have defined a function in mainactivity now i want to access with another class in my app.I have created a object of the mainactivity by using that object i have called th
Make the variable public and then create object in adapter like this:
public int i; // Variable in Activity class ((ActivityName) context).i // accessing in adapter