Added error message and clear screen for user readability.