Operation cannot be completed, because the current user does not have sufficient permissions on the instance of SQL Server. ...

Operation cannot be completed, because the current user does not have sufficient permissions on the instance of SQL Server. User must have VIEW DEFINITION, ALTER ANY LOGIN and SELECT ON sys.sql_expression_dependencies or be a member of the db_owner database role and securityadmin fixed server role.