Android: Data from Broadcast from AsyncTask not getting data through
<p>I am using an Intent to Broadcast data from a AsyncTask thread back to a the main Activity.  The Broadcast is received my the Activity with no problem, but I am not seeing the Uri data or CharSequence data.  They are both null.</p>

<p>On Service side in AsyncTask:</p>

<pre><code>   public static final String LOCATION_UPDATE = "com.locationTest.lct.LOCATION_UPDATE";
   char[] buffer = new char[10];
   buffer[0] = 't';
   buffer[1] = 'e';
   buffer[2] = 's';
   buffer[3] = 't';

   Intent intent = new Intent(LOCATION_UPDATE);
   intent.putExtra("location",buffer);
   sendBroadcast(intent);
</code></pre>

<p>On activity side in main Activity class:</p>

<pre><code>public static final String LOCATION_UPDATE = "com.locationTest.lct.LOCATION_UPDATE";
   public class LocationBroadcastReceiver extends BroadcastReceiver {
       public void onReceive(Context context,Intent intent)
       {
        Uri data = intent.getData();
        CharSequence location = intent.getCharSequenceExtra("location");
    }
}
@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);

    iService = startService(new Intent(this,InputService2.class));
    IntentFilter filter = new IntentFilter(LOCATION_UPDATE);
    LocationBroadcastReceiver r = new LocationBroadcastReceiver();
    registerReceiver(r,filter);  
</code></pre>
