Hi All,

I'm using the following code in an attempt to get notification that
the phone state has changed.  However, when I run it on the emulator I
can make and receive calls without ever triggering my breakpoint on
the 'Log.d' line.  Can anyone tell me what I'm doing wrong here?

<manifest package="com.technicana.customercontact"
xmlns:android="http://schemas.android.com/apk/res/android";>
        <uses-permission android:name="android.permission.READ_PHONE_STATE"></
uses-permission>
        <receiver android:name=".CallBroadcastReceiver">
                <intent-filer>
                        <action
android:name="android.telephony.TelephonyManager.ACTION_PHONE_STATE_CHANGED"/
>
                </intent-filer>
        </receiver>
</manifest>

And the code file: CallBroadCastReceiver.java

package com.technicana.customercontact;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;

public class CallBroadcastReceiver extends BroadcastReceiver {

        @Override
        public void onReceive(Context context, Intent intent) {
                // TODO Auto-generated method stub
                Log.d("Here", "Broadcast received");
        }

}

Regards,

Chris Spicer

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to