formatting numerical data in text fields correctly