In my app, I need to edit an bluetooth-transferred file just after it is received.
Exactly what Intent do I have to listen to with my BroadcastReceiver, in o
If the user gets a file via android OS, it's via the download manager. in that case u should register DownloadManager.ACTION_DOWNLOAD_COMPLETE
private void registerBroadcastReceiver() {
broadCastReceiver = new BroadcastReceiver() {
public void onReceive(Context context, Intent intent) {
String action = intent.getAction();
if (DownloadManager.ACTION_DOWNLOAD_COMPLETE.equals(action)) {
//your code here
}
}
};
IntentFilter filter = new IntentFilter(DownloadManager.ACTION_DOWNLOAD_COMPLETE);
registerReceiver(broadCastReceiver, filter);
}