Added messageBox if export is not valid