locked
Httprequest Winrt RRS feed

  • Question

  • i was working on HttpWebrequest Mothoed Post i an have this exception showing up  

    L’application a appelé une interface qui était maintenue en ordre pour un thread différent. (Exception de HRESULT : 0x8001010E (RPC_E_WRONG_THREAD))

    public void ResponseReady(IAsyncResult asyncResult) { HttpWebRequest request = asyncResult.AsyncState as HttpWebRequest; HttpWebResponse response = (HttpWebResponse)request.EndGetResponse(asyncResult); Stream responseStream = response.GetResponseStream(); XmlReader reader = XmlReader.Create(responseStream); XElement element = XElement.Load(reader); var slides = from slide in element.Descendants("item") select new Anonce { title = Corrction_String((string)slide.Element("title")), date = Corrction_String((string)slide.Element("pubDate")), Body = Corrction_String((string)slide.Element("description")), }; foreach (Anonce a in slides) Auto.Add(a); AutoListBox.ItemsSource = Auto.ToList(); //the exception showed in the binding

    }


    Wednesday, October 10, 2012 11:29 AM

Answers