如何将Windows窗体和Web service结合使用
xytme 2003-06-25 06:16:21 我需要在Web Service中调用Window窗体,但是没有反映,我想可能Web Service工程和ASP.Net一样,不可以显示窗体.
[WebMethod]
public string test()
{
System.Windows.Forms.Form testForm=new System.Windows.Forms.Form();
testForm.Show();
return testForm.Left.ToString();//返回创建窗体的位置
}
实际上我是需要在窗体上绘制一些东西,然后返回窗体显示的一些信息,所以必须显示窗体,如果不能在Web Service工程中创建窗体,那么可不可以在Window应用程序中创建Web Service,因为Web Service实际上发送的是TCP,所以我想是可以创建的,不知道具体如何来作!分不够再加