Exemple #1
0
        public static int EditAccount(int user_ID, string userName, string firstName, string lastName, string middleName, string emailAddress, string userPassword)
        {
            int        updateid = Variables.UID;
            UsersModel data     = new UsersModel
            {
                User_ID      = user_ID,
                UserName     = userName,
                FirstName    = firstName,
                LastName     = lastName,
                MiddleName   = middleName,
                EmailAddress = emailAddress,
                UserPassword = userPassword
            };

            string sql = @"update dbo.UserInfo set User_ID = @User_ID, UserName = @UserName, FirstName = @FirstName, LastName = @LastName, MiddleName = @MiddleName, EmailAddress = @EmailAddress, UserPassword = @UserPassword where Id =" + updateid.ToString() + ";";



            return(SqlDataAccess.EditData(sql, data));
        }