user3778410
user3778410

Reputation: 51

Get incoming call event

How can we register to listen for an incoming call event in Windows 10 UWP on a mobile device ?

I tried Windows Call Sample but it works only for unknown dialers. I've also tried to register the sample with different PhoneTriggerType but that doesn't seem to work.

Upvotes: 3

Views: 282

Answers (1)

Elvis Xia - MSFT
Elvis Xia - MSFT

Reputation: 10831

I tried Windows Call Sample but it works only for unknown dialers. I've also tried to register the sample with different PhoneTriggerType but that doesn't seem to work.

If you want to listen for any incoming call event. You can use PhoneCallManager.CallStateChanged event like below:

PhoneCallManager.CallStateChanged += (o, args) =>
{
       If(PhoneCallManager.IsCallIncoming)
       {
           // do your things
       } 
};

And also don't forget to make your app the default Phone Call APP on your device.

Upvotes: 1

Related Questions