I believe the way you have coded @IsMember will only return True if the user has ALL 5 roles. You may want to code it this way:
@If(@IsNotMember("[ROLEA]" : "[ROLEB]" : "[ROLEC]" : "[ROLED]" : "[ROLEE]" ; @UserRoles); @Command([FileCloseWindow]); @Command([FileSave]))
So if the user does not have ANY of those roles, then return True and close the window. Otherwise, if they have one or more of those roles, return False and save the document.
Hope that helps.