欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  移动技术

Windows Phone 7 开发之Microsoft.Phone.Tasks中的各项Task

程序员文章站 2022-04-12 09:13:01
  //phonecalltask :打电话          private void btnpho...

 

//phonecalltask :打电话 

        private void btnphonecall_click(object sender, routedeventargs e) 

        { 

            phonecalltask task = new phonecalltask(); 

 

            task.phonenumber = "110"; 

 

            task.displayname = "亚"; 

 

            task.show();   www.2cto.com

        } 

  

//smscomposetask:发送短信  

        private void btncomposesms_click(object sender, routedeventargs e) 

        { 

            smscomposetask task = new smscomposetask(); 

 

            task.to = "110"; 

 

            task.body = "你好!."; 

 

            task.show(); 

        } 

  

//emailcomposetask:发送邮件 

  

            emailcomposetask task = new emailcomposetask(); 

 

            task.to = "252456098@qq.com"; 

 

            task.cc = "ycproc@163.com"; 

 

            task.subject = "测试"; 

  

            task.body = "hello world!"; 

 

            task.show(); 

  

  

  

//webbrowsertask:开启web 

       private void btnlaunchwebbrowser_click(object sender, routedeventargs e) 

        { 

            webbrowsertask task = new webbrowsertask(); 

 

            task.url = "<a href="https://blog.csdn.net/fengyarongaa">https://blog.csdn.net/fengyarongaa</a>"; 

            task.show(); 

        } 

  

//searchtask:搜索功能 

        private void btnlaunchsearch_click(object sender, routedeventargs e) 

        { 

            searchtask task = new searchtask(); 

            task.searchquery = "亚"; 

            task.show(); 

        } 

  

//mediaplayerlauncher:启动媒体播放器 

   mediaplayerlauncher task = new mediaplayerlauncher(); 

   task.media = new uri(@"https://ecn.channel9.msdn.com/o9/learn/videos/silverlight4-sl4businessmodule1-sl4lob_01_01_introduction/silverlight4-sl4businessmodule1-sl4lob_01_01_introduction_kit.wmv"); 

   task.show();   

作者:_亚