I just quite don't understand how to use the two...

This is what I have so far, am I even on the right track? And I do
appreciate the response...

import android.app.Service;
import android.content.Context;
import android.content.Intent;
import android.os.IBinder;
import android.telephony.PhoneStateListener;
import android.telephony.TelephonyManager;

public class incomingCallService extends Service
{
  @Override
  public void onCreate()
  {
          //Actions to do when Service is created
  }

  @Override
  public IBinder onBind(Intent intent)
  {
          //Replace with service binding implementation.
          return null;
  }

  @Override
  public void onStart(Intent intent, int StartId)
  {
          String srvcName = Context.TELEPHONY_SERVICE;
          TelephonyManager telephonyManager = (TelephonyManager)
getSystemService(srvcName);
  }

  public class PhoneListener extends PhoneStateListener
  {

  }
}

On May 25, 3:01 am, Mark Murphy <[email protected]> wrote:
> GT wrote:
> > Does anybody have an example of using the PhoneState Listener while
> > running a service? I've been having problems having a PhoneState
> > Listener inside of the service.
>
> I don't have an example I can publish, but it definitely works. What
> specifically has been your issue?
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Android App Developer Training:http://commonsware.com/training.html
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to