private M_UserInfo LoginByRegID(ref string errmsg, string AdminName, string AdminPass, int RegID) { AdminName = AdminName.Trim(); AdminPass = AdminPass.Trim(); M_UserInfo info = new M_UserInfo(true); switch (RegID) { case 1: errmsg = "邮箱名或密码错误"; info = buser.AuthenticateEmail(AdminName, AdminPass); break; case 2: errmsg = "用户ID或密码错误"; info = buser.AuthenticateID(DataConverter.CLng(AdminName), AdminPass); break; case 3: errmsg = "手机号码或密码错误"; info = buser.AuthenByMobile(AdminName, AdminPass); break; case 4: errmsg = "用户名或密码错误"; info = buser.AuthenByUME(AdminName, AdminPass); break; default: errmsg = "用户名或密码错误"; info = buser.AuthenticateUser(AdminName, AdminPass); break; } return(info); }