Launcher的使用

 

附带代码:

/// <summary>

/// 拨打电话按钮事件处理

/// </summary>

/// <param name="sender"></param>

/// <param name="e"></param>

private void btnPhoneCall_Click(object sender, RoutedEventArgs e)

{

      PhoneCallTask phoneCall = new PhoneCallTask();//定义并实例化

      phoneCall.PhoneNumber = txbPhoneOrEmail.Text.Trim();//PhoneNumber获取或设置启动手机应用程式拨打的电话号码

      phoneCall.DisplayName = "TestNumber";//DisplayName获取或设置启动手机应用程序时显示的名称

      phoneCall.Show();//Show显示手机应用程序

}

/// <summary>

/// 发送短信按钮事件处理

/// </summary>

/// <param name="sender"></param>

/// <param name="e"></param>

private void btnSendSms_Click(object sender, RoutedEventArgs e)

{

      SmsComposeTask sendSms = new SmsComposeTask();

      sendSms.To = txbPhoneOrEmail.Text.Trim();//To获取或设置新短信的收件人列表

      sendSms.Body = "hello,这是一条来自windows phone7的测试信息";//Body获取或设置新短信的正文文本

      sendSms.Show();

}

 

/// <summary>

/// 发送邮件按钮事件处理

/// </summary>

/// <param name="sender"></param>

/// <param name="e"></param>

private void btnSendEmail_Click(object sender, RoutedEventArgs e)

{

      EmailComposeTask sendEmail = new EmailComposeTask();

      sendEmail.To = txbPhoneOrEmail.Text.Trim();//To获取或设置新邮件的收件人。

      sendEmail.Subject = "hello,这是一条来自windows phone7的测试邮件";//Subject获取或设置电子邮件的主题

      sendEmail.Body = "这是测试邮件的内容";//Body获取或设置新电子邮件的正文

      sendEmail.Show();

}

 

 

你可能感兴趣的:(Launcher,launcher使用)