error_vars function

Generate Variables for Error Loop