I have this two classes. My main Activity and the one that extends the AsyncTask, Now in my main Activity I need to get the result from the OnPostExecute(
AsyncTask
OnPostExecute(
You can try this code in your Main class. That worked for me, but i have implemented methods in other way
try { String receivedData = new AsyncTask().execute("http://yourdomain.com/yourscript.php").get(); } catch (ExecutionException | InterruptedException ei) { ei.printStackTrace(); }