android error occured while executing doInBackground()
<p>I am getting the error 'error occured while executing doInBackground()'</p>

<p>Here is my ASyncTask class:</p>

<pre><code>private class ASyncPollServer extends AsyncTask&lt;String, Void, String&gt;{

    @Override
    protected String doInBackground(String... params) {
        String pollResult = "";
        if(((ChatApplication) _instance.getApplication()).isPolling() == false){
        ((ChatApplication) _instance.getApplication()).setPolling(true);
        pollResult = ((ChatApplication) _instance.getApplication()).GetConnectionManager().PollServer();
    }
        return pollResult;
        }

    @Override
    protected void onPostExecute(String result) {
        if(result != ""){
            HandlePollResult(result);
            ((ChatApplication) _instance.getApplication()).setPolling(false);
        }

    }

}
</code></pre>

<p>And my TimerTask to call it:</p>

<pre><code>private Handler handler = new Handler();
public class ServerPollTimer extends TimerTask {
    private Runnable runnable = new Runnable() {
        public void run() {
            ExecutePollServer();
        }
    };

    public void run() {
        handler.post(runnable);
        }
    }
</code></pre>

<p>And my ExecutePollServer method:</p>

<pre><code>private void ExecutePollServer(){
    ASyncPollServer task = new ASyncPollServer();
    task.execute();
}
</code></pre>

<p>And where I call the timer in the OnCreate():</p>

<pre><code>new Timer().schedule(new ServerPollTimer() , 0, 5000);
</code></pre>

<p>Here is my stacktrace:</p>

<pre><code>05-30 09:46:16.020: E/AndroidRuntime(340): FATAL EXCEPTION: AsyncTask #1
05-30 09:46:16.020: E/AndroidRuntime(340): java.lang.RuntimeException: An error occured while executing doInBackground()
05-30 09:46:16.020: E/AndroidRuntime(340):  at android.os.AsyncTask$3.done(AsyncTask.java:200)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.util.concurrent.FutureTask$Sync.innerSetException(FutureTask.java:274)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.util.concurrent.FutureTask.setException(FutureTask.java:125)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:308)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.util.concurrent.FutureTask.run(FutureTask.java:138)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1088)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:581)
05-30 09:46:16.020: E/AndroidRuntime(340):  at java.lang.Thread.run(Thread.java:1019)
05-30 09:46:16.020: E/AndroidRuntime(340): Caused by: java.lang.IllegalStateException: No wrapped connection.
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.impl.conn.AbstractClientConnAdapter.assertValid(AbstractClientConnAdapter.java:163)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.impl.conn.AbstractClientConnAdapter.sendRequestEntity(AbstractClientConnAdapter.java:269)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.protocol.HttpRequestExecutor.doSendRequest(HttpRequestExecutor.java:237)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:119)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:421)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:555)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:487)
05-30 09:46:16.020: E/AndroidRuntime(340):  at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:465)
05-30 09:46:16.020: E/AndroidRuntime(340):  at chatclient.utility.HttpPostNetworkUtility.PerformPost(HttpPostNetworkUtility.java:43)
05-30 09:46:16.020: E/AndroidRuntime(340):  at chatclient.utility.ConnectionManager.ExecuteCommand(ConnectionManager.java:213)
05-30 09:46:16.020: E/AndroidRuntime(340):  at chatclient.utility.ConnectionManager.PollServer(ConnectionManager.java:192)
05-30 09:46:16.020: E/AndroidRuntime(340):  at chatclient.namespace.MainWindowActivity$ASyncPollServer.doInBackground(MainWindowActivity.java:402)
05-30 09:46:16.020: E/AndroidRuntime(340):  at chatclient.namespace.MainWindowActivity$ASyncPollServer.doInBackground(MainWindowActivity.java:1)
</code></pre>

<p>Any help would be GREATLY appreciated!</p>

<p>Thank you!</p>
