读书人

好不容易找了个异步调用ws,哪位高手能

发布时间: 2012-02-05 12:07:15 作者: rapoo

好不容易找了个异步调用ws,谁能给看看
void DoSomethingTest()
{
localhost.Service service = new WindowsApp.localhost.Service();

service.HelloWorldCompleted += new WindowsApp.localhost.HelloWorldCompletedEventHandler(service_HelloWorldCompleted);
// do Asyn calling here
service.HelloWorldAsync();
}

void service_HelloWorldCompleted(object sender, WindowsApp.localhost.HelloWorldCompletedEventArgs e)
{
if (e.Error == null)
{
MessageBox.Show(e.Result);
}
else
{
MessageBox.Show(e.Error.Message);
}
}


是c#的,我用vb ,试着改了一下,不能用,谁给翻译一下,谢谢!!!!


[解决办法]
这儿有一段,可以参考
http://blog.csdn.net/kevin521/archive/2004/10/27/151078.aspx

读书人网 >VB Dotnet

热点推荐