Android 1.5 Spare parts Battery History does not display any data

by Jeff Sharkey » Thu, 21 May 2009 05:22:15 GMT


Sponsored Links
 Because the emulator doesn't have a battery?

j






-- 
Jeff Sharkey
jshar...@android.com

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. IntentDemo

Hi

I have recorded my second screencast which talks at a very basic level
about Intents. here is the link

http://blip.tv/file/997147

The sound quality is unfortunately low and I am trying to remedy that
for my subsequent demonstrations. Any of your [other] comments /
criticisms are most welcome. Simply visit http://sleepydroid.blogspot.com
and drop me an email.

Regards
D.
--~--~---------~--~----~------------~-------~--~----~

2. parse XML from http response

Hi all,

i need Your help:

i become XML output from  server (who needs username and password for 
access)  and i d like to read the information in my android app. I've 
made HttpConnection to connect the server and authenticate. Then i read 
the HttpResponse - it looks like this:

private void getResponse() {
        try {
             //huc ist the HttpURLConnection

            StringBuffer sb = new StringBuffer(huc.getContentLength());
            InputStreamReader isr = new 
InputStreamReader(huc.getInputStream(),"UTF-8");
            char buff[] = new char[huc.getContentLength()];
            int n;
            while ((n = isr.read(buff, 0, huc.getContentLength() - 1)) > 
0) {
                sb.append(buff, 0, n);
            }
            response = sb.toString();  //as String is easy ...  but with 
the xml elements ... see next:
            isr.close();
           
        } catch (IOException e1) {
            // TODO Auto-generated catch block
            e1.printStackTrace();
        }

        try {
               //now i need to parse this output into Array only with 
the attributs from the
               XMLHandler h = new XMLHandler();
               SAXParserFactory f = SAXParserFactory.newInstance();
               SAXParser sp = f.newSAXParser();
               XMLReader xr = sp.getXMLReader();
               xr.setContentHandler(h);
               sp.parse(huc.getInputStream(), h);  // here is my 
problem: parse does not support Stream input ..
    
              }

           catch (SAXParseException error) {

               Log.d("\nParse Error", "\n Num: " + error.getLineNumber());
               Log.d("\n", error.getMessage() );
               }catch (Throwable t) {
               t.printStackTrace();
               }
    }

any help is welcome!
thanks
dey


--~--~---------~--~----~------------~-------~--~----~

3. Camera Test Phone

4. Thread safety of using a Handler

5. A Bitmap/Drawable from GTalk avatar?

6. Where do you embed application version ?

7. Help on porting with ME4Android