我怎样才能发现,如果一个Web服务正在运行或不?或不、正在运行、发现、Web

由网友(等不到你)分享简介:我要检查网络服务的可用性。这是我的我运行一个函数从Web服务I want to check availability of web service.this is my code that i running a function from web serviceDataSet ds = new DataSet...

我要检查网络服务的可用性。 这是我的我运行一个函数从Web服务

I want to check availability of web service. this is my code that i running a function from web service

DataSet ds = new DataSet();
DataTable dt = new DataTable();
NegsoNotifier.WorkItemsService.WorkItemsSoapClient wiservice;

wiservice = new NegsoNotifier.WorkItemsService.WorkItemsSoapClient();
System.ServiceModel.EndpointAddress adr;
adr = new System.ServiceModel.EndpointAddress(Weburl);
wiservice.Endpoint.Address = adr;
//wiservice.Open();

ds = wiservice.GetMyWorkItems(Username, Password);
dt = ds.Tables[0];

我如何理解这个Web服务正在运行或不?

How can I understand this Web service is running or not?

推荐答案

如果该服务的答案,那么它运行。如果有一个答案是正确的问题答案,那么它的正常运行。

If the service answers, then it was running. If it answers with an answer that is correct for the question, then it's running correctly.

请注意,它可以运行,但没有运行的正确的。例如,它需要一个数据库服务器可能已关闭。

Note that it could be running, but not running correctly. For instance, a database server that it needs might be down.

阅读全文

相关推荐

最新文章