Running the Project

Before you run the project, make sure that all of the files you created are stored in the proper folders. The eventreg.mdb database should be in the \bookdata\project2 folder, eventreg.dll should be in the \scripts\project2 folder, and eventreg.htm and backgnd2.gif should be in the \wwwroot\project2 folder. Make sure that eventreg.dll is properly registered and that the ACTION attribute of the frmRegister form in eventreg.htm is properly defined. Additionally, oleisapi.dll must be in the scripts folder. For more information on setting up the oleisapi.dll, see "Setting Up OLEISAPI," in Chapter 5 (page 156). Once everything is properly configured, you should be able to open the web page in the Internet Explorer and view the event registration form.

Wait a few moments after the page loads. You should see the text change in the ActiveX label at the top of the page. This indicates that the Timer control and associated VBScript code are working correctly. If the code is correct, a new random message will appear every 5 seconds.

Test the client-side validation routine by leaving a text field blank. As you tab to a new field, the VBScript code will detect the blank text box and stop you. You should see an appropriate message prompting you to enter some text.

Figure 7-11 shows the event registration form and a message box prompting the user to enter text.

Figure 7-11.

The event registration form and a message box prompting the user to enter text.

After checking the validation procedure, fill out the form and submit it to the back end by clicking on the Register Now! button. You should receive an appropriate confirmation message from the server. You can check to see whether your data is in the database by opening the database in the Data Manager or in Microsoft Access.

© 1996 by Scot Hillier. All rights reserved.