INFO: Modifying Data Form Wizard Generated ASP Pages

ID: Q168421


The information in this article applies to:


SUMMARY

Microsoft Visual InterDev contains wizards for the generation of sample Active Server Pages (ASP). These pages serve as an example of the capabilities of Visual InterDev and Active Server Pages. Microsoft Technical Support does not provide support for changes made to these pages.


MORE INFORMATION

Using the Data Form Wizard in Visual InterDev you can create a form based upon a data source. When completed you will have three ASP documents in the form of the following:


   xxxxAction.asp
   xxxxForm.asp
   xxxxList.asp 
Where xxxx is the file name provided to the wizard when you select it from the File menu, New option.

Microsoft Technical Support (MTS) can help troubleshoot problems in the default code created by the Data Form wizard. If any alterations are made to the code, the code is no longer considered Wizard code. Instead it is now considered "user code," and MTS will be unable to assist in troubleshooting.

For assistance from MTS, problems will need to be isolated from Wizard code and duplicated in a simple example. MTS can help resolve issues with these simple examples.

Document Information

xxxxAction.asp:

The xxxxAction.asp file is responsible for reacting to user interaction with either the xxxxList.asp or the xxxxForm.asp files. It consists of several functions defined within the <SCRIPT> tags at the beginning of the .asp file. When the file is called, it looks to see what button was pressed, and reacts accordingly. After performing some action, it redirects the browser to either the xxxForm.asp or the xxxxList.asp files.

xxxxForm.asp:

The xxxxForm.asp file is called initially and displays a single record from the database table or recordset. It consists of four major sections. The first section sequentially is the various VBScript functions called by the form. The most important of which is the ShowFields function which is responsible for taking a field name, and showing it in the HTML document. The second major section is an ActiveX design-time control, the Data Range Header. The data range header is followed by some more VBScript code that calls the ShowFields function for each field in the recordset. Finally another ActiveX design-time control is used. This is the Data Range Footer. This simply acts as the end of a loop established by the Data Range Header.

xxxxList.asp:

The xxxxList.asp file is very similar to the xxxxForm.asp file. It contains the same sections in the same order with one exception. This file displays multiple records at a time in a list format within an HTML table. Before the Data Range header Design-time control is the <TABLE> tag and the column headings.


REFERENCES

For the latest Knowledge Base articles and other support information on Visual InterDev and Active Server Pages, see the following page on the Microsoft Technical Support site:

http://support.microsoft.com/support/vinterdev/

Additional query words:


Keywords          : kbsample kbwizard kbVBScript kbVisID kbVisID100 kbGrpASP 
Version           : WINDOWS:1.0
Platform          : WINDOWS 
Issue type        : kbinfo 

Last Reviewed: May 10, 1999