silverlight頁面的代碼??private void enter_Click(object sender, RoutedEventArgs e)? {? Service1SoapClient client = new Service1SoapClient();? string name = this.Name.Text;? string pwd = this.Pwd.Password;? int i=client.select_adminAsync(name,pwd);? }webservice頁面的代碼?[WebMethod]? public int select_admin(string name,string pwd)? {? string sql = "select * from admin where Name='" + name + "'and Password='" + pwd + "'";? DataSet ds = DbHelpSQL.ExecuteGetData(sql);? if (ds.Tables[0].Rows.Count > 0)? {? return 1;? }? else? {? return 0;? }為什么調(diào)用方法的時候會說無法將void隱士轉(zhuǎn)換為int 我方法的返回值明明是int 該怎么樣才可以調(diào)用或者獲取返回值
- 1 回答
- 0 關(guān)注
- 367 瀏覽
添加回答
舉報
0/150
提交
取消