示例#1
0
        public string Save(string name)
        {
            int  n;
            bool a = int.TryParse(name, out n);

            if (name != " ")
            {
                if (a == false)
                {
                    if (aTestGateway.IsTestTypeExist(name) == false)
                    {
                        int rowAffected = aTestGateway.Save(name);
                        if (rowAffected >= 0)
                        {
                            return("Save Successfull");
                        }

                        return("Save Unsuccessfull");
                    }

                    return("Type Name already exist ");
                }

                return("Type Name is invalid");
            }
            return("Type Name is empty");
        }