/// <summary>
 /// 触发HTTP请求完成方法
 /// </summary>
 /// <param name="e">事件参数</param>
 public void OnHttpCompleted(WP7HttpEventArgs e)
 {
     if (this.httpCompleted != null)
     {
         this.httpCompleted(this, e);
     }
 }
        /// <summary>
        /// 异步响应回调函数
        /// </summary>
        /// <param name="asyncResult">异步请求参数</param>
        private void handleResponse(IAsyncResult asyncResult)
        {
            string result = "";
            bool iserror = false;
            try
            {
                HttpWebRequest webRequest = asyncResult.AsyncState as HttpWebRequest;
                HttpWebResponse webResponse = (HttpWebResponse)webRequest.EndGetResponse(asyncResult);
                Stream streamResult = webResponse.GetResponseStream(); //获取响应流
                StreamReader reader = new StreamReader(streamResult);
                result = reader.ReadToEnd();
            }
            catch (Exception ex)
            {
                iserror = true;
                result = ex.Message;
            }
            finally
            {
                WP7HttpEventArgs e = new WP7HttpEventArgs();
                e.isError = iserror;
                e.result = result;
                //进行异步回调操作
                System.Windows.Deployment.Current.Dispatcher.BeginInvoke(delegate()
                {

                    OnHttpCompleted(e);

                });
            }
        }