A method and apparatus for populating a form with data is described. In
one embodiment of the invention, a form is displayed to the user via the
target application. Each form has one or more data receptacles. The data
receptacles of a form are filled with data when the user executes a data
population command. The form completion program executes the data
population command when a graphical representation of a particular data
set is placed over the form. Each data set is stored in an encrypted
manner and is accessible to users who enter the appropriate information
into an authentication mechanism. To populate a form with data the form
completion program obtains an image of the form and then searches for a
template file that resembles the form image to within a certain
threshold. The template files are typically stored on the computer
hosting the target application in a template directory that is arranged
according to a predefined structure. The form completion program is
configured to search for templates that resemble the form image in the
template directory to within a certain threshold.