Updates to Maximize Second Monitor Function

Made updates to commenting and added meaningful error checking.