VB CGI Application

Dear Dr. GUI:

I have installed Internet Information Server. How can I write a CGI application in Visual Basic 4.0? Where can I find a sample?

Antonio Mastrobuono

Dr. GUI replies:

There are two ways to do this.

If you really have to use common gateway interface (CGI), there's a program called WinCGI that redirects the stdin stream to an .INI file. (The CGI standard passes parameters to the program via stdin.) You can read the .INI file from a Visual Basic program. Dr. GUI doesn't recommend this because of the heavy server overhead of CGI programs, not to mention the file overhead and string processing needed to handle the .INI file.

Dr. GUI's prescription is to do it a better way: use ISAPI via the OLEISAPI DLL and the automation objects it exposes.

OLEISAPI is a sample in the ISAPI section of the ActiveX SDK (http://www.microsoft.com/intdev/sdk).