Sunday, August 30, 2009

Android Input Validation

Today's article will cover a quick and dirty approach to form validation for Android applications. My application has an activity that displays a form to the user for entering personal information. This information is then stored in a SQLite database. I needed a way to validate the data in the form's widgets before saving that data in the application's database. The Android framework provides some support for entering valid data into a form. This support includes hints and input filters. Hints are a handy way to help a user enter information when a widget's text is empty.