Refactor Outlook sample app