I need suggestion as to what is the best way to achieve this: I want to be able to run a function which requires access to my sqlite database by clicking on an option inside my preferences. I have been able to create a PreferenceFragment that properly manages my preferences.
I have been trying to find a way to directly call a function in my main activity but did not find any simple solution.
Is it possible to do such thing without a need to access main activity?