7,657
社区成员
发帖
与我相关
我的任务
分享
AppService.ChineseTeachingAppWebServiceSoapClient appservice = new AppService.ChineseTeachingAppWebServiceSoapClient();
string account = txtAccount.Text;
string pwd = txtPwd.Password;
appservice.LoginCompleted += (s, arg) =>
{
Dispatcher.BeginInvoke(() =>txtTS.Text = arg.Result.ToString());
};
appservice.LoginAsync(account,pwd);
AppService.ChineseTeachingAppWebServiceSoapClient appservice = new AppService.ChineseTeachingAppWebServiceSoapClient();
string account = txtAccount.Text;
string pwd = txtPwd.Text;
string a = appservice.Login(account,pwd);
Response.Write(a);
//return loginQuery.ToList().Count > 0 ? true : false;
windowsPhone调用代码:AppService.ChineseTeachingAppWebServiceSoapClient appservice = new AppService.ChineseTeachingAppWebServiceSoapClient();
string account = txtAccount.Text;
string pwd = txtPwd.Password;
appservice.LoginCompleted += (s, arg) =>
{
Dispatcher.BeginInvoke(() => txtTS.Text = arg.Result.ToString());
};
appservice.LoginAsync(account, pwd);
<configuration>
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="ChineseTeachingAppWebServiceSoap" maxBufferSize="2147483647"
maxReceivedMessageSize="2147483647">
<security mode="None" />
</binding>
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://localhost:3835/ChineseTeachingAppWebService.asmx"
binding="basicHttpBinding" bindingConfiguration="ChineseTeachingAppWebServiceSoap"
contract="AppService.ChineseTeachingAppWebServiceSoap" name="ChineseTeachingAppWebServiceSoap" />
</client>
</system.serviceModel>
</configuration>