using flash to display errors