Example #1
0
        public string Save(Student student)
        {
            bool regExist = gateway.DoesRegNoExist(student.RegistaionNo);

            if (regExist)
            {
                return("Registation number already exist");
            }
            else
            {
                int rowAffacted = gateway.Save(student);
                if (rowAffacted > 0)
                {
                    return("Saved Successfully");
                }
                else
                {
                    return("Saving Failed");
                }
            }
        }