The first thing in the result form is a local declaration of a GBMain form object to receive the object when it's passed as a property. The code to create the property is next. Only the Set code block needs a line of code to assign the passed GBMain form object to the local variable MainForm.
Three events are handled but most of the work is done by the DisplayForm subroutine called by both the Load event and the Click event for the Next button. The Load event simply makes sure the form text boxes are initialized with the first returned Google result element and the Next button Click event just increments a counter for the result elements and checks for the maximum value.
The DisplayForm subroutine checks to see if an error is being passed. If an error has been passed, then the contents of the text boxes have been assigned by GBMain already so nothing is done. In the normal case, fields passed back from the web service are simply assigned to form components.
So, where are we now?
The resulting program works, but there are still a lot of things that could be improved. One is that Google passes back HTML formatted text which is not interpreted by the standard text box components. Another is that only single words and phrases can be selected. We'll work on these problems in a future article. If you would like to try your hand at solving them yourself, you can download the source for the program here.

