Use MSI_IterateRecords for processing actions. Some whitespace cleanup and replace a comment block I did not want to remove.