Problem to open SMS after deleting another with my widget...

by Olivier » Wed, 10 Mar 2010 17:55:24 GMT

Sponsored Links
It is the last problem I have before finishing my widget so I beg you
to help me!
I've created a widget wich can navigate in SMS/Inbox, and deleting
When I delete one at the position 5 for example, this one is deleted,
the other next are at the position before and the messages before the
one deleted don't change of position... All seem's to bee right... but
the sms at postion 5 is null and so can't be open... When I exit from
the widget and relaunch it, all seem's normal, and the sms at position
5 is the old at position 6, what is expected...
I use the classic method:
Uri uri=Uri.parse("content://sms/Inbox");
Cursor cursor=getContentResolver()query(uri,null,null,null,null);

But I think that there is a probleme because the sms database isn't
close unless I close my widget.
So can I force android to close it and reopen after, or shoold I use
TWOpenHelper openHelper = new TWOpenHelper(context);
SQLiteDatabase database = openHelper.getReadableDatabase();
in this last case I think I need the real uri of sms database (data/
data/<package_name>/databses) wich is?...

thank's for giving me your opinion and really hope a little help to
finish it.


Other Threads

1. Running Android Image from memory card?


Is it possible to boot the phone (ADP1) from a compiled android image
stored on the memory card without affecting the contents of the image
flashed on the phone?

I would like to do this so I can work with development images, but I
didn't want to mess with the factory image.



2. How to capture ACTION_MOVE MotionEvents in a view

That is because returning true says that you consumed the event and thus the
rest of the events in that motion will be dispatched to that view.

Dianne Hackborn
Android framework engineer

Note: please don't send private questions to me, as I don't have time to
provide private support.  All such questions should be posted on public
forums, where I and others can see and answer them.


3. X11 module?

4. Fwd: GMAPS is not being displayed in the emulator

5. Gps one assisted GPS

6. Why I can't delete SIM record?

7. multiple google accounts