HttpServerUtility.CreateObject HttpServerUtility.CreateObject HttpServerUtility.CreateObject HttpServerUtility.CreateObject Method

Definition

Creates a server instance of a COM object.

Overloads

CreateObject(String) CreateObject(String) CreateObject(String) CreateObject(String)

Creates a server instance of a COM object identified by the object's programmatic identifier (ProgID).

CreateObject(Type) CreateObject(Type) CreateObject(Type)

Creates a server instance of a COM object identified by the object's type.

CreateObject(String) CreateObject(String) CreateObject(String) CreateObject(String)

Creates a server instance of a COM object identified by the object's programmatic identifier (ProgID).

public:
 System::Object ^ CreateObject(System::String ^ progID);
public object CreateObject (string progID);
member this.CreateObject : string -> obj
Public Function CreateObject (progID As String) As Object

Parameters

progID
String String String String

The class or type of object to create an instance of.

Returns

The new object.

Exceptions

An instance of the object could not be created.

Examples

The following example creates an object by using the object's ProgID.

Object MyObject;
MyObject = Server.CreateObject("Acme.Component.3");
   
Dim MyObject As Object
MyObject = Server.CreateObject("Acme.Component.3")
   
See also

CreateObject(Type) CreateObject(Type) CreateObject(Type)

Creates a server instance of a COM object identified by the object's type.

public:
 System::Object ^ CreateObject(Type ^ type);
public object CreateObject (Type type);
member this.CreateObject : Type -> obj

Parameters

type
Type Type Type Type

A Type representing the object to create.

Returns

The new object.

Applies to