NotificationManager crashes only in Device
<p>I have a problem that I can't explain. I have a main activity which contains a button. When this button is clicked, it launches a new activity which downloads an xml file from the internet. While downloading there is a notification that indicates the download progress. This works perfect in my AVD (api level 17). When I try to do the same thing in my device (GT-I1900 with api level  10, version 2.3.3) it crashes. I think that the problem exists with the notification Builder that I use.</p>

<pre><code>Context context = getApplicationContext();
notificationManager = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
notificationBuilder = new NotificationCompat.Builder(this);
notificationBuilder.setContentTitle("Download Progress").setContentText("Downloading").setSmallIcon(android.R.drawable.stat_sys_download);
</code></pre>

<p><strong>...</strong></p>

<pre><code>notificationManager.notify(0, notificationBuilder.build());
</code></pre>

<p>For the download I use a DownloadFilesTask (extends AsyncTask) class which I have tested and works fine.</p>

<p>Here is the exception log:</p>

<pre><code>    at android.app.NotificationManager.notify(NotificationManager.java:91)
</code></pre>

<p>So my question is if the problem do exists with the API level of my device. If it does, can anyone explain me how to use notification builder for lower APIs</p>

<p>Here is the full log:</p>

<pre><code>02-01 23:06:28.862: E/AndroidRuntime(16860): FATAL EXCEPTION: AsyncTask #1
02-01 23:06:28.862: E/AndroidRuntime(16860): java.lang.RuntimeException: An error occured while executing doInBackground()
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.os.AsyncTask$3.done(AsyncTask.java:200)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.FutureTask$Sync.innerSetException(FutureTask.java:274)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.FutureTask.setException(FutureTask.java:125)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:308)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1088)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:581)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.lang.Thread.run(Thread.java:1019)
02-01 23:06:28.862: E/AndroidRuntime(16860): Caused by: java.lang.IllegalArgumentException: contentIntent required: pkg=com.bakoproductions.easybet id=0 notification=Notification(vibrate=null,sound=null,defaults=0x0,flags=0x0)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.os.Parcel.readException(Parcel.java:1326)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.os.Parcel.readException(Parcel.java:1276)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.app.INotificationManager$Stub$Proxy.enqueueNotificationWithTag(INotificationManager.java:322)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.app.NotificationManager.notify(NotificationManager.java:111)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.app.NotificationManager.notify(NotificationManager.java:91)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at com.bakoproductions.easybet.XMLParser.downloadXML(XMLParser.java:83)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at com.bakoproductions.easybet.DownloadFilesTask.doInBackground(DownloadFilesTask.java:24)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at com.bakoproductions.easybet.DownloadFilesTask.doInBackground(DownloadFilesTask.java:1)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at android.os.AsyncTask$2.call(AsyncTask.java:185)
02-01 23:06:28.862: E/AndroidRuntime(16860):    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:306)
02-01 23:06:28.862: E/AndroidRuntime(16860):    ... 4 more
</code></pre>
