Re: [android-developers] How to update the media database

2011-03-09 Thread Robin Talwar
I think i have to call finish() and then somehow run the activity in order to show the updated list On Thu, Mar 10, 2011 at 3:19 AM, Robin Talwar wrote: > Well this is what i got when i checked my logcat > > 03-10 03:17:27.732: ERROR/MediaScannerService(401): Failed to delete file > /data/data/co

Re: [android-developers] How to update the media database

2011-03-09 Thread Robin Talwar
Well this is what i got when i checked my logcat 03-10 03:17:27.732: ERROR/MediaScannerService(401): Failed to delete file /data/data/com.android.providers.media/pause_scan when i start the intent again to check the list of tracks then i get this error while if i restart the application then i do

Re: [android-developers] How to update the media database

2011-03-09 Thread Robin Talwar
I needed to add the following code :- sendBroadcast(new Intent(Intent.ACTION_MEDIA_MOUNTED, Uri.parse("file://" + Environment.getExternalStorageDirectory(; in my class file and following in manifest :- But i can not get the updated list at that very instant On Thu, Mar 10, 2011 at 3

Re: [android-developers] How to update the media database

2011-03-09 Thread Robin Talwar
Thanks trekking I am able to update the music list now but to see the updated list now i dont have to restart my phone but restart the application. Well somewhat close but not enough :) On Thu, Mar 10, 2011 at 2:17 AM, TreKing wrote: > On Wed, Mar 9, 2011 at 2:35 PM, Robin Talwar > wrote: > >>

Re: [android-developers] How to update the media database

2011-03-09 Thread TreKing
On Wed, Mar 9, 2011 at 2:35 PM, Robin Talwar wrote: > But i want to update the list the time the user clicks the "Delete" button. See if this helps: http://developer.android.com/reference/android/media/MediaScannerConnection.html -

Re: [android-developers] How to update the media database

2011-03-09 Thread Robin Talwar
the code that i am using right now is File f = new File(PathToFile); f.delete(); and when i switch off the phone and switch on again then the database is updated and i am shown the correct list. But i want to update the list the time the user clicks the "Delete" button. Any help will be much appre

[android-developers] How to update the media database

2011-03-09 Thread Abhishek Talwar
Can we update the database?? Since i am deleting the songs from sdcard so i would like to show the updated list when delete button is clicked -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-devel