Skip to content Skip to sidebar Skip to footer

Not Found Activity To Handle Intent?

I am writing a program where the main activity in my app should be invoked when a particular SMS arrives on the phone. I have already registered a BroadcastReceiver and the intent

Solution 1:

Try to change your <intent-filter> like this:

<intent-filter><actionandroid:name="edu.example.prankssms3.action.STARTMUSIC" /><categoryandroid:name="android.intent.category.DEFAULT" /></intent-filter>

Solution 2:

Lanching an activity from a broadcast receiver is an not usual operation. Trying adding FLAG_ACTIVITY_NEW_TASK to the Intent you use for startActivity().

Calling startActivity() from outside of an Activity context requires the FLAG_ACTIVITY_NEW_TASK flag. Hopefully this will solve your problem.

Post a Comment for "Not Found Activity To Handle Intent?"