C++ Interfaces for the ASP Built-In Objects

IIS 6.0

ASP implements interfaces that enable your component to access the properties and methods of the ASP built-in objects. You should use the COM+ IObjectContext interface to access the ASP built-in object interfaces. Your component can then use the ASP built-in object interfaces to access the properties, methods, and collections of the ASP built-in objects.

The following table lists the ASP built-in object interfaces:

Interface

Description

IApplicationObject C++ Interface

Provides access to the methods of the Application Object object.

IASPError C++ Interface

Returned by the IServer::GetLastError method. Provides access to the read-only properties describing the last error event.

IObjectContext

Returns an interface to one of the ASP built-in objects: IApplicationObject Java Interface, IRequest Java Interface, IResponse Java Interface, IServer Java Interface, or ISessionObject Java Interface. Provides transaction control. For more information about the COM+ ObjectContext object, see Accessing ASP Built-In Objects from Components Reference. For complete information on the IObjectContext interface, see the COM+ Programmer's Reference of the Software Developer Kit (SDK).

IReadCookie C++ Interface

Provides access to the values stored in the read-only Request object Request.Cookies Collection collection.

IRequest C++ Interface

Provides access to the methods and properties of the Request Object object.

IRequestDictionary C++ Interface

Indexes the sub-collections of the IRequest interface. You can also use it to retrieve the individual values stored in the Request.ClientCertificate Collection collection.

IResponse C++ Interface

Provides access to the methods and properties of the Response Object object.

IScriptingContext C++ Interface (Obsolete)

Returns a pointer to an interface on one of the ASP built-in objects: IApplicationObject C++ Interface, IRequest C++ Interface, IResponse C++ Interface, IServer C++ Interface, or ISessionObject C++ Interface. This interface is no longer supported. Instead, use the COM+ IObjectContext interface.

IServer C++ Interface

Provides access to the methods and properties of the Server Object object.

ISessionObject C++ Interface

Provides access to the methods and properties of the Session Object object.

IStringList C++ Interface

Provides access to the values stored in a string list, such as that in the Request.QueryString Collection, Request.Form Collection, or Request.ServerVariables Collection collections.

IVariantDictionary C++ Interface

Provides access to the items stored in the Application and Session Contents and StaticObjects collections.

IWriteCookie C++ Interface

Sets the values and attributes of a cookie stored in the write-only Response object Response.Cookies Collection collection.

Microsoft ® Visual C++ ® provides the ActiveX ® Template Library (ATL) 1.1 to make the development of COM components faster. To use ATL, select ATL COM Appwizard when you create a new project workspace.

To use the IObjectContext object interface in a C++ component, you must include the header file Comsvcs.h (formerly known as Mtx.h) as shown in the following code:


#include "comsvcs.h" 

To use the IScriptingContext object interface in a C++ component, you must include the header file Asptlb.h as shown in the following code:


#include "asptlb.h" 

These header files are part of the Software Developer Kit (SDK).

Client: Requires Windows XP Professional, Windows 2000 Professional, or Windows NT Workstation 4.0.

Server: Requires Windows Server 2003, Windows 2000 Server, or Windows NT Server 4.0.

Product: IIS

Show: