1

Android - How to Handle an Async Http Crash

view story
linux-howto

http://stackoverflow.com – My app is currently crashing whenever it cannot connect to the server. How do I handle this, and instead let the user know that the server is down and to try again. private void sendPostRequest(String givenEmail, String givenPassword) { class SendPostRequestTask extends AsyncTask<String, Void, String> { @Override protected String doInBackground(String... params) { String emailInput = params[0]; String passwordInput = params[1]; String jsonUserInput = "{email: " + emailInput + ", password: " + passwordInput + (HowTos)