tags:

views:

96

answers:

1

i have created an application in android version1.6 with eclipse to get the weather details from an url. the application has run successfull for 2 months and all of sudden it is throwing "Launch Timeout has expired, giving up wake lock!" and followed by "Activity idle timeout for HistoryRecord {438b31f8 com.weahter/.Weather}. kindly give me solution for this problem.

A: 

This is the code i am using to retive the data. please tell me where i am worng.

try { URL rssUrl2 = new URL("http://xoap.weather.com/search/search?where=Amsterdam, Netherlands"); SAXParserFactory mySAXParserFactory2 = SAXParserFactory.newInstance(); SAXParser mySAXParser2 = mySAXParserFactory2.newSAXParser(); XMLReader myXMLReader2 = mySAXParser2.getXMLReader(); RSSHandler myRSSHandler2 = new RSSHandler(); myXMLReader2.setContentHandler(myRSSHandler2); InputSource myInputSource2 = new InputSource(rssUrl2.openStream());

                myXMLReader2.parse(myInputSource2);


                urlConn2 = rssUrl2.openConnection();
                try {
                DocumentBuilderFactory dbf2 = DocumentBuilderFactory.newInstance();
                DocumentBuilder db2 = dbf2.newDocumentBuilder();
                doc2 = db2.parse(urlConn2.getInputStream());
            } catch (IOException ioe) {

                } catch (ParserConfigurationException pce) {        
                } catch (SAXException se) {
                }
subbu