It is the program you sent me. I noticed that I have to debug as an Android to get the Log.d statements to work.
************************************************************ package com.needham.RxBcast; import android.content.BroadcastReceiver; import android.content.ComponentName; import android.content.Context; import android.content.Intent; import android.util.Log; public class RxBcast extends BroadcastReceiver { private static final String TAG = "RxBcast77"; private static final int NOTE_ID = 1; @Override public void onReceive(Context c, Intent i) { // check and handle registerable actions String act = i.getAction(); Log.d(TAG, "Rxd7777 "+ act ); if( act.equals(i.ACTION_BOOT_COMPLETED) ) { Intent si = new Intent(c, PiesOfCodActivity.class); si.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); c.startActivity(si); } } // onReceive } ********************************************************************* package com.needham.RxBcast; import android.app.Activity; import android.os.Bundle; import android.util.Log; import android.widget.TextView; public class PiesOfCodActivity extends Activity { /** Called when the activity is first created. */ private static final String TAG = "RxBcast77"; public void onCreate(Bundle savedInstanceState) { Log.d(TAG, "POCA777 "+ savedInstanceState ); super.onCreate(savedInstanceState); TextView tv = new TextView(this); tv.setText("Hello, Pies of Cod!"); setContentView(tv); } } ****************************************************************************** <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.needham.RxBcast" android:versionCode="1" android:versionName="1.0" > <uses-sdk android:minSdkVersion="7" /> <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" /> <application android:icon="@drawable/ic_launcher" android:label="@string/app_name" > <activity android:name=".PiesOfCodActivity" android:label="@string/app_name" > <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> <!-- android.intent.action.BOOT_COMPLETED --> <receiver android:name="com.needham.PiesOfCod.RxBcast" > <intent-filter> <action android:name="android.intent.action.BOOT_COMPLETED" /> </intent-filter> <intent-filter> <action android:name="com.needham.PiesOfCode.LAUNCH_APP" /> </intent-filter> </receiver> </application> </manifest> On Feb 23, 2:16 pm, Ted Scott <t...@hootinholler.com> wrote: > On 2/23/2012 11:18 AM, Thomas wrote:> I've continued to experiment. I wanted > to send an attachment file but > > but here is a portion of the logcat showing the RxBcast failing at > > bootup and after the Emulator is opened then running correctly. > > look for ****** I unlock emulator > > The same thing happens on my DroidX2 Fails on boot after keyboard is > > unlocked and then works correct when started by touching icon. > > > ******* Bad stuff here > > E/AndroidRuntime( 237): FATAL EXCEPTION: mainE/AndroidRuntime( 237): > > java.lang.RuntimeException: Unable to instantiate receiver > > com.needham.PiesOfCod.RxBcast: java.lang.ClassNotFoundException: > > com.needham.PiesOfCod.RxBcast in loader dalvik.system.PathClassLoader[/ > > data/app/com.needham.RxBcast-1.apk]E/AndroidRuntime( 237): at > > android.app.ActivityThread.handleReceiver(ActivityThread.java:2789)E/ > > Looks like a configuration issue. Before you started experimenting, did > you get the stuff I posted working? > > What's in your manifest? What does your project's code tree look like? -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en