wp7手机拨打长途电话

 由于入手wp7手机,发现每次打长途都没有加17951(记不住别人号码)

xap文件下载见附件,源码如下:由于学习中,写的不好 请勿拍砖,谢谢

using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using Microsoft.Phone.Controls;
using Microsoft.Phone.Tasks;

namespace IPCall
{
    public partial class MainPage : PhoneApplicationPage
    {
        PhoneCallTask phoneTask;
        PhoneNumberChooserTask phoneNumber;
        // 构造函数
        public MainPage()
        {
            InitializeComponent();

            phoneTask = new PhoneCallTask();
            phoneNumber = new PhoneNumberChooserTask();
            phoneNumber.Completed+=new EventHandler<PhoneNumberResult>(PhoneNumber_Completed);
        }
       
        private void btn_Contacts_Click(object sender, RoutedEventArgs e)
        {
            phoneNumber.Show();
        }
        void PhoneNumber_Completed(object sender, PhoneNumberResult e)
        {
            if (e.TaskResult == TaskResult.OK)
            {
                this.txt_IpCode.Text += e.PhoneNumber;
            }
        }
        private void btn_Call_Click(object sender, RoutedEventArgs e)
        {
            phoneTask.PhoneNumber = txt_IpCode.Text;
            phoneTask.Show();
        }
    }
}

你可能感兴趣的:(WP7手机,长途电话)