Trying to download info from a website in android app?
<p>i start a activity and i call this download method in on create</p>

<pre><code>public void download(){
 thread = new Runnable () {
       public void run() {     
      try{
                /* Get a SAXParser from the SAXPArserFactory. */
    SAXParserFactory spf =    SAXParserFactory.newInstance();
    SAXParser sp = spf.newSAXParser();

        Get the XMLReader of the SAXParser we created. */
    XMLReader xr = sp.getXMLReader();

    /*
     * Create a new ContentHandler and apply it to the
     * XML-Reader                */
    WeatherHandler gwh = new GoogleWeatherHandler();
    xr.setContentHandler(gwh);
    /* Parse the xml-data our URL-call returned. */
        temp////is a url defined
        xr.parse(new InputSource(temp.openStream()));

    ws = gwh.getWeatherSet();
}
    catch(Exception e){

    }                     
    }new Thread(thread).start();

 }
</code></pre>

<p>Problem is that it works if I debug and actually go over the line <code>thread.start</code>, if not the thread does not start? how can i just download info from a website?</p>
