Platform SDK: DirectX

DirectDraw7.GetDirect3D

The DirectDraw7.GetDirect3D method creates a Direct3D7 object.

object.GetDirect3D() As Direct3D7

Parameters

object
Object expression that resolves to a DirectDraw7 object.

Return Values

If the method succeeds, it returns a Direct3D7 object.

Error Codes

If the method fails, it raises an error, and Err.Number can be set to one of the following values:

E_INVALIDINTERFACE
E_OUTOFMEMORY

For information on trapping errors, see Visual Basic Error Trapping.

Remarks

The object returned by a successful function call must be assigned to a Direct3D7 object variable. For example:

Dim Direct3D as Direct3D7
Set Direct3D = object.GetDirect3D()