Привет! Мне нужно получить данные из веб-службы и поместить их в текстовый блок. следующий код дает мне пустой текстовый блок есть ли проблемы с моим кодом
????
public info()
{
InitializeComponent();
WebClient inf = new WebClient();
// client.DownloadStringCompleted += new DownloadStringCompletedEventHandler(client_DownloadStringCompleted);
inf.DownloadStringCompleted+=new DownloadStringCompletedEventHandler(inf_DownloadStringCompleted);
//name.Text =
}
public void inf_DownloadStringCompleted(object sender, DownloadStringCompletedEventArgs e)
{
string pass = mp.passwordBox1.Password;
string id = mp.tx.Text;
string url = "http://82.212.89.6:888/mob/resources/stdInfo/authenticate/" +id + "/" +pass + "/1/570322308ce1121cba1b93f5acc9ebd4733ef2bca90ef942a2cfa224f0aa08dc/1";
XElement xx = XElement.Parse(url);
string m= xx.Element("userId").Value;
name.Text = m;
}