Using Check Boxes and Radio Buttons with MFC Parse Maps (174831)



The information in this article applies to:

  • Microsoft Visual C++ .NET (2003)
  • The Microsoft Foundation Classes (MFC), when used with:
    • Microsoft Visual C++, 32-bit Editions 4.1
    • Microsoft Visual C++, 32-bit Editions 4.2
    • Microsoft Visual C++, 32-bit Editions 5.0
    • Microsoft Visual C++ .NET (2002)

This article was previously published under Q174831
Note Microsoft Visual C++ .NET (2002) supports both the managed code model that is provided by the Microsoft .NET Framework and the unmanaged native Microsoft Windows code model. The information in this article applies only to unmanaged Visual C++ code.

SUMMARY

This article contains an example of how to use HTML Check Boxes and Radio Buttons with an MFC ISAPI Parse Map.

Following are some important points:
  • Either a numeric or string value can be used for the VALUE tag in the HTML form, as long as the corresponding Parse Map parameter matches.
  • A unique NAME must be used for each Check Box; the MFC Parse Map cannot properly enumerate multiple instances of the same form variable.
  • A default value must be defined for each Check Box/Radio Button parameter in the MFC Parse Map. If this is not done, the browser will receive an error if a Check Box is left unselected, or no selection is made in a group of Radio Buttons.

MORE INFORMATION

The sample below contains a Visual C++ 5.0 project created with the ISAPI Extension Wizard, and an HTML file containing sample forms to be submitted to the ISAPI DLL. The HTML file should be placed in the same virtual directory as the compiled DLL. The following file is available for download from the Microsoft Download Center:
For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 How to Obtain Microsoft Support Files from Online Services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.

Modification Type:MinorLast Reviewed:8/5/2004
Keywords:kbdownload kbfile kbinfo kbSample KB174831 kbAudDeveloper