Module pythoncom

A module, encapsulating the OLE automation API

Methods

_GetInterfaceCount
Retrieves the number of interface objects currently in existance 

_GetInterfaceCount
Retrieves the number of gateway objects currently in existance 

CoCreateFreeThreadedMarshaler
Creates an aggregatable object capable of context-dependent marshaling. 

CoCreateInstanceEx
Create a new instance of an OLE automation server possibly on a remote machine. MS_WINCE 

CoCreateInstance
Create a new instance of an OLE automation server. 

CoFreeUnusedLibraries
Unloads any DLLs that are no longer in use and that, when loaded, were specified to be freed automatically. 

CoInitialize
Initialize the COM libraries for the calling thread. 

CoInitializeEx
Initialize the COM libraries for the calling thread. 

CoInitializeSecurity
Registers security and sets the default security values. 

CoGetInterfaceAndReleaseStream
Unmarshals a buffer containing an interface pointer and releases the stream when an interface pointer has been marshaled from another thread to the calling thread. 

CoMarshalInterThreadInterfaceInStream
Marshals an interface pointer from one thread to another thread in the same process. 

CoMarshalInterface
Marshals an interface into a stream 

CoUnmarshalInterface
Unmarshals an interface 

CoReleaseMarshalData
Frees resources used by a marshalled interface MS_WINCE 

CoGetObject
Converts a display name into a moniker that identifies the object named, and then binds to the object identified by the moniker. 

CoUninitialize
Uninitialize the COM libraries. 

CoRegisterClassObject
Registers an EXE class object with OLE so other applications can connect to it. 

CoResumeClassObjects
Called by a server that can register multiple class objects to inform the OLE SCM about all registered classes, and permits activation requests for those class objects. 

CoRevokeClassObject
Informs OLE that a class object, previously registered with the pythoncom::CoRegisterClassObject method, is no longer available for use. 

CoTreatAsClass
Establishes or removes an emulation, in which objects of one class are treated as objects of a different class. 

CoWaitForMultipleHandles
Waits for specified handles to be signaled or for a specified timeout period to elapse. 

Connect
Connects to a running instance of an OLE automation server. 

CreateGuid
Creates a new, unique GUIID. 

CreateBindCtx
Obtains a PyIBindCtx object. 

CreateFileMoniker
Creates a file moniker given a file name. 

CreateItemMoniker
Creates an item moniker that identifies an object within a containing object (typically a compound document). 

CreatePointerMoniker
Creates a pointer moniker based on a pointer to an object. 

CreateURLMoniker
Create a URL moniker from a full url or partial url and base moniker 

CreateTypeLib
Provides access to a new object instance that supports the ICreateTypeLib interface. 

CreateTypeLib2
Provides access to a new object instance that supports the ICreateTypeLib2 interface. MS_WINCE 

CreateStreamOnHGlobal
Creates an in-memory stream storage object 

CreateILockBytesOnHGlobal
Creates an ILockBytes interface based on global memory 

EnableQuitMessage
Indicates the thread PythonCOM should post a WM_QUIT message to. 

FUNCDESC
Returns a new FUNCDESC object. 

GetActiveObject
Retrieves an object representing a running object registered with OLE 

GetClassFile
Supplies the CLSID associated with the given filename. MS_WINCE 

GetFacilityString
Returns the facility string, given an OLE scode. 

GetRecordFromGuids
Creates a new record object from the given GUIDs 

GetRecordFromTypeInfo
Creates a PyRecord object from a PyITypeInfo interface 

GetRunningObjectTable
Obtains a PyIRunningObjectTable object. MS_WINCE 

GetScodeString
Returns the string for an OLE scode. 

GetScodeRangeString
Returns the scode range string, given an OLE scode. 

GetSeverityString
Returns the severity string, given an OLE scode. 

IsGatewayRegistered
Returns 1 if the given IID has a registered gateway object. 

LoadRegTypeLib
Loads a registered type library by CLSID 

LoadTypeLib
Loads a type library by name 

MakePyFactory
Creates a new PyIClassFactory object wrapping a PythonCOM Class Factory object. 

MkParseDisplayName
Parses a moniker display name into a moniker object. The inverse of IMoniker::GetDisplayName. MS_WINCE 

New
Create a new instance of an OLE automation server. 

ObjectFromAddress
Returns a COM object given its address in memory. 

ObjectFromLresult
Retrieves a requested interface pointer for an object based on a previously generated object reference. 

OleInitialize
 

OleGetClipboard
Retrieves a data object that you can use to access the contents of the clipboard. 

OleFlushClipboard
Carries out the clipboard shutdown sequence. It also releases the IDataObject pointer that was placed on the clipboard by the pythoncom::OleSetClipboard function. 

OleIsCurrentClipboard
Determines whether the data object pointer previously placed on the clipboard by the OleSetClipboard function is still on the clipboard. 

OleSetClipboard
Places a pointer to a specific data object onto the clipboard. This makes the data object accessible to the OleGetClipboard function. 

OleLoadFromStream
Load an object from an IStream. 

OleSaveToStream
Save an object to an IStream. 

OleLoad
Loads into memory an object nested within a specified storage object. 

ProgIDFromCLSID
Converts a CLSID string to a progID. MS_WINCE 

PumpWaitingMessages
Pumps all waiting messages for the current thread. 

PumpMessages
Pumps all messages for the current thread until a WM_QUIT message. 

QueryPathOfRegTypeLib
Retrieves the path of a registered type library MS_WINCE 

ReadClassStg
Reads a CLSID from a storage object 

ReadClassStm
Reads a CLSID from a PyIStream object 

RegisterTypeLib
Adds information about a type library to the system registry. 

UnRegisterTypeLib
Removes a type library from the system registry. 

RegisterActiveObject
Register an object as the active object for its class 

RevokeActiveObject
Ends an object’s status as active. 

RegisterDragDrop
Registers the specified window as one that can be the target of an OLE drag-and-drop operation. 

RevokeDragDrop
Revokes the specified window as the target of an OLE drag-and-drop operation. 

DoDragDrop
Carries out an OLE drag and drop operation. MS_WINCE 

StgCreateDocfile
Creates a new compound file storage object using the OLE-provided compound file implementation for the PyIStorage interface. 

StgCreateDocfileOnILockBytes
Creates a new compound file storage object using the OLE-provided compound file implementation for the PyIStorage interface. 

StgIsStorageFile
Indicates whether a particular disk file contains a storage object. MS_WINCE 

STGMEDIUM
Creates a new PySTGMEDIUM object suitable for the PyIDataObject interface. 

StgOpenStorage
Opens an existing root storage object in the file system. 

StgOpenStorageEx
Access IStorage and IPropertySetStorage interfaces for normal files 

TYPEATTR
Returns a new TYPEATTR object. 

VARDESC
Returns a new VARDESC object. 

WrapObject
Wraps an object in a gateway. 

WriteClassStg
Stores a CLSID from a storage object 

WriteClassStm
Sets the CLSID of a stream 

UnwrapObject
Unwraps a Python instance in a gateway object. 

FmtIdToPropStgName
Convert a FMTID to its stream name 

PropStgNameToFmtId
Convert property set name to FMTID 

Properties

int frozen
1 if the host is a frozen program, else 0

int dcom
1 if the system is DCOM aware, else 0. Only Win95 without DCOM extensions should return 0