Added argument checking to ProcessText.