windowservice中service怎么调用web应用程序当中的方法、?在windowservice中直接添加引用、web应用程序当中的方法出现未实例化

解决方案 »

  1.   

    window service 定时发送数据库中发送出去的短信
    短信发送方法调用web应用程序层发送方法    web应用程序方法已经调用了webservice实现了发送功能
      

  2.   

     既然出现,未将方法实例化 ,那你在调用的时候 new 一下不可以么?
      

  3.   

     webserice  ss = new webserice
      

  4.   

    昏,这连个能结合起来吗?貌似不容易...基本不这么做吧,最多DAL,BLL公用
      

  5.   

    好像windowservice不能直接调用到ui、DAL、BLL层不知哪个有做个这样调用、、急求解决方法、、
      

  6.   

    ui不能调用,DAL,BLL项目直接被windowservice引用就行了
      

  7.   


      System.Text.Encoding encoder = System.Text.Encoding.GetEncoding("GB2312");
                            string url = string.Format("http://webservice.kltx10000.com/service.asmx/SendSMS?uc={0}&pwd={1}&callee={2}&cont={3}&msgid={4}&otime={5}", PublicClass.SMSUser_cn, PublicClass.SMSPassword_cn, mobileNumber, content, dataId, now);
                            System.Net.WebClient wClient = new System.Net.WebClient();
                            string msg = System.Text.Encoding.Default.GetString(wClient.DownloadData(url));
                            wClient.Dispose();
      

  8.   

    在windowservice上建立多个service如何让多个service实现异步运行、