on the other hand what is the purpose of the message box if on OK click the code would continue. It would be more logical to collect all errors and show msgbox on code completion with processing results