Мое приложение всегда падает, когда я пытаюсь создать Уведомление, падает только на Android 3.0.
03-05 21:23:00.774: ERROR/ActivityManager(66): Activity Manager Crash
03-05 21:23:00.774: ERROR/ActivityManager(66): java.lang.IllegalArgumentException: Null intent at index 0
03-05 21:23:00.774: ERROR/ActivityManager(66): at com.android.server.am.ActivityManagerService.getIntentSender(ActivityManagerService.java:3907)
03-05 21:23:00.774: ERROR/ActivityManager(66): at android.app.ActivityManagerNative.onTransact(ActivityManagerNative.java:799)
03-05 21:23:00.774: ERROR/ActivityManager(66): at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java:1516)
03-05 21:23:00.774: ERROR/ActivityManager(66): at android.os.Binder.execTransact(Binder.java:320)
03-05 21:23:00.774: ERROR/ActivityManager(66): at dalvik.system.NativeStart.run(Native Method)
03-05 21:23:00.784: WARN/dalvikvm(458): threadid=9: thread exiting with uncaught exception (group=0x40014760)
03-05 21:23:00.814: ERROR/AndroidRuntime(458): FATAL EXCEPTION: Thread-10
03-05 21:23:00.814: ERROR/AndroidRuntime(458): java.lang.IllegalArgumentException: Null intent at index 0
03-05 21:23:00.814: ERROR/AndroidRuntime(458): at android.os.Parcel.readException(Parcel.java:1326)
03-05 21:23:00.814: ERROR/AndroidRuntime(458): at android.os.Parcel.readException(Parcel.java:1276)
03-05 21:23:00.814: ERROR/AndroidRuntime(458): at android.app.ActivityManagerProxy.getIntentSender(ActivityManagerNative.java:2356)
03-05 21:23:00.814: ERROR/AndroidRuntime(458): at android.app.PendingIntent.getActivity(PendingIntent.java:195)
03-05 21:23:00.814: ERROR/AndroidRuntime(458): at com.perlapps.myantivirus.scanmethodes.UpdateDatabase$1.run(UpdateDatabase.java:244)
Кто-нибудь есть идеи, как это исправить ???
Редактировать: отлично работает на 1,5 до 2,3
NotificationManager meinNM = (NotificationManager) oContext.getSystemService(Context.NOTIFICATION_SERVICE);
Notification meinNotofication = new Notification(R.drawable.icon,"HELLO",System.currentTimeMillis());
PendingIntent pendingIntent = PendingIntent.getActivity(oContext.getApplicationContext(),0, null, 0);
meinNotofication.setLatestEventInfo(oContext.getApplicationContext(),"HELLO","HELLO",pendingIntent);
meinNM.notify(97, meinNotofication);