/* public static List<MobileOneTest.Employee> getEmployees(MobileOneTest.Department department) { ISqlMapper mapper = EntityMapper; List<MobileOneTest.Employee> employees = mapper.QueryForList<MobileOneTest.Employee>("GetEmployees", department).ToList(); return employees; } public static string FindDepartment(int deptId) { ISqlMapper mapper = EntityMapper; string str = mapper.QueryForObject<string>("FindDepartment", deptId); return str; } */ private void button1_Click(object sender, EventArgs e) { try { UserModel userModel = new UserModel(); User user = userModel.SqlFind(10000); if (user.Name != null) MessageBox.Show(user.Name); } catch (Exception ie) { MessageBox.Show(ie.Message); } }