The Associated Industries of Massachusetts Business Confidence Index fell in July after two consecutive months of gains.