There are several ways to avoid a criminal conviction on your record.