Random complete loss of database on Droid only

by Jonas Petersson » Thu, 22 Apr 2010 14:20:34 GMT


Sponsored Links
 (long)time(!C);  // ;-)




I have no real clue to offer, but I can say that my Milestone (which is 
pretty much the same as a Droid) has had no problems what so ever with 
your app. The initial 2.0 had plenty of other issues of which most were 
fixed in 2.0.1. Mine is UK registered so I've not got my 2.1 yet (should 
be any day now since I can see FR and ES users already have it).


My main remaining issue with the Milestone is that it will occasionally 
hang or reboot, typically either while playing Bebbled or just after 
I've used the debugger and unplugged (while the debugger was still 
active). I guess such a crash COULD break your database if it is being 
written to at the time.


                        Best / Jonas

--



Random complete loss of database on Droid only

by Chander Pechetty » Thu, 22 Apr 2010 15:02:13 GMT


 Interesting, I had filed an issue earlier with my G1 crashing
occasionally when playing bebbled; wonder if they are related ( to
cosmic rays :-)

 http://code.google.com/p/android/issues/detail?id=6478 

There is a lengthy discussion on loss of database at


Sponsored Links


Other Threads

1. Editing XML files using DOM in Android

Hi all ,
I am developing an application where i need to update a value in an
XML file according to the value entered by the user  and send this
updated file to some server.I am using DOM to do this ..but the
problem is that the function setNodeValue does not seem to
work ....When i print the value after changing the content it gives
the same value as before ...

Code:

                         NodeList list = null;
                        DocumentBuilderFactory dbf = 
DocumentBuilderFactory.newInstance();


                        //xmlFile = fileName;
                        try
                        {
                                DocumentBuilder db = dbf.newDocumentBuilder();
                                InputStream istream = null;
           istream=(this.mCtx).getResources().openRawResource
(R.raw.currencyconverter);
                            xmlDoc2 = db.parse(istream);

                        Element docEle = xmlDoc2.getDocumentElement();
                        list = docEle.getElementsByTagName("Variable");
                         for (int j = 0; j < list.getLength(); j++)
                    {
                        Node child = list.item(j);
                        if (child.getNodeType() == Node.ELEMENT_NODE) {
                       Element element=(Element)child;
                       setTextValue(element,"contentvalue","1000");
        System.out.println("This is the text value"+getTextValue
(element,"contentvalue"));


                        }
                    }

                        }

                        catch (Exception e)
                        {
                                e.printStackTrace();

                        }
This is the setTextValue method :

 private static void setTextValue(Element ele,String tagName,String
Value)
         {


        try {
                 NodeList nl = ele.getElementsByTagName(tagName);
                 if (nl != null && nl.getLength() > 0)
                 {

                          Element el = (Element) nl.item(0);

                         if (el.getFirstChild() != null)
                         {
                                 el.getFirstChild().setNodeValue(Value);
                              // This is the statement which does not
seem to work

                         }

                 }
        }
            catch (Exception e)
            {

             e.printStackTrace();

            }

         }



Please help.... i am not able to understand what is happening .
THANKS.


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

2. Android design question

The system in place to pass information between the screens... I am
confused why the team chose to reinvent the wheel via the putExtras
methods.  Instead of making the transport objects inherit from
Parcelable and the like, why not just use Java's OO strength and set
objects to Activities themselves.  For instance, like this:


class Caller extends Activity {
   public on buttonClick() {
          ThisScreen ts = new ThisScreen();
          ts.SetCustomValue(10);

          startActivity(ts)
   }
}

class ThisScreen extends Activity {
   public void onCreate() {
       txtBox.setText(Integer.toString(i));
   }

   public void SetCustomValue (int i) {
            ...
   }
}

Instead we are having to unnecessarily learn new concepts.  Was there
a compelling reason to implement it they it's implemented that I am
not seeing?

Thanks.

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

3. startActivityForResult problems

4. SSL client authentication

5. What's the bar at the top of the screen called?

6. Touchscreen PenMoun

7. does anyone try using this application - PHONEPLUS CALLBACK?