I did a major update of my question because some misunderstandings.
So, I have a notification. And when I click that notification, I want the file explorer app (third party app of course) opens. No matter whuch app is, if there's more than on file explorers, it should prompt the "open with" - and then open /sdcard/folder (if possible)
My notification it's here on Listar.class
NotificationManager manager = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE); Notification notification = new Notification(R.drawable.ic_menu_save, msg, System.currentTimeMillis()); PendingIntent contentIntent = PendingIntent.getActivity(this, 0, new Intent(this, Open.class), 0); notification.setLatestEventInfo(this, filename+" downloaded", "Click to open folder", contentIntent); manager.notify(1, notification);
and my Open class it's here:
public class Open extends Activity { public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); try{ Intent intent = new Intent("org.openintents.action.PICK_FILE"); startActivityForResult(intent, 1); } catch(Exception e) { Toast.makeText(this, e.toString(), Toast.LENGTH_LONG).show(); Log.v("EX",e.toString()); } } }
This opens oi file manager (without "open with" - i didnt chose default app) and to /sdcard, that's why i need your help.