Freigeben über


Automation Functions

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

The following table shows the Automation functions with a description of the purpose of each.

Note

Windows Mobile may not support all of the programming elements in this section. For information about differences between the COM implementation available for Windows Mobile devices and that available for Windows Embedded CE devices, see COM and DCOM in Windows Mobile Devices.

Programming element Description

BstrFromVector

This function returns a BSTR, assigning each element of the vector to a character in the BSTR.

CreateErrorInfo

This function creates an instance of a generic error object.

CreateTypeLib2

This function creates a type library in the file/in-memory format that makes use of memory-mapped files for 32-bit platforms.

DispGetIDsOfNames

This function uses type information to convert a set of names to DISPIDs.

DispGetParam

This function retrieves a parameter from the DISPPARAMS structure, checks both named parameters and positional parameters, and coerces the parameter to the specified type.

DispInvoke

This function automatically calls member functions on an interface, given the type information for the interface.

GetErrorInfo

This function obtains the error information pointer set by the previous call to SetErrorInfo in the current logical thread.

LoadRegTypeLib

This function uses registry information to load a type library.

LoadTypeLib

This function loads and registers a typelib2 type library.

RegisterTypeLib

This function adds information about a type library to the system registry.

SafeArrayAccessData

This function increments the lock count of an array, and retrieves a pointer to the array data.

SafeArrayAllocData

This function allocates memory for a safearray, based on a descriptor created with SafeArrayAllocDescriptor.

SafeArrayAllocDescriptor

This function allocates memory for a safearray descriptor, allowing the creation of safearrays that contain elements with data types other than those provided by SafeArrayCreate.

SafeArrayCopy

This function creates a copy of an existing safearray.

SafeArrayCopyData

This function copies the source array to the target array after releasing any resources in the target array.

SafeArrayCreate

This function creates a new array descriptor, allocates and initializes the data for the array, and returns a pointer to the new array descriptor.

SafeArrayCreateVector

This function creates a one-dimensional array whose lower bound is always zero.

SafeArrayDestroy

This function destroys an existing array descriptor and all of the data in the array.

SafeArrayDestroyData

This function destroys all the data in a safearray.

SafeArrayDestroyDescriptor

This function destroys a descriptor of a safearray.

SafeArrayGetDim

This function returns the number of dimensions in the array.

SafeArrayGetElement

This function retrieves a single element of the array.

SafeArrayGetElemsize

This function retrieves the size (in bytes) of the elements of a safearray.

SafeArrayGetLBound

This function returns the lower bound for any dimension of a safearray.

SafeArrayGetUBound

This function returns the upper bound for any dimension of a safearray.

SafeArrayLock

This function increments the lock count of an array, and places a pointer to the array data in pvData of the array descriptor.

SafeArrayPtrOfIndex

This function returns a pointer to an array element.

SafeArrayPutElement

This function assigns a single element to the array.

SafeArrayRedim

This function changes the right most or least significant bound of a safearray.

SafeArrayUnaccessData

This function decrements the lock count of an array, and invalidates the pointer retrieved by SafeArrayAccessData.

SafeArrayUnlock

This function decrements the lock count of an array so it can be freed or resized.

SetErrorInfo

This function sets the error information object for the current thread of execution.

SysAllocString

This function allocates a new string and copies the passed string into it.

SysAllocStringByteLen

This function takes an ANSI string as input, and returns a BSTR that contains an ANSI string.

SysAllocStringLen

This function allocates a new string, copies cch characters from the passed string into it, and then appends a null character.

SysFreeString

This function frees a string allocated previously by SysAllocString, SysAllocStringByteLen, SysReAllocString, SysAllocStringLen, or SysReAllocStringLen.

SysReAllocString

This function allocates a new BSTR and copies the passed string into it, then frees the BSTR referenced by pbstr, and finally resets pbstr to point to the new BSTR.

SysReAllocStringLen

This function creates a new BSTR that contains a specified number of characters from an old BSTR, and frees the old BSTR.

SysStringByteLen

This function returns the length (in bytes) of a BSTR.

SysStringLen

This function returns the length of a BSTR.

SystemTimeToVariantTime

This function converts the variant representation of time to system-time values.

UnRegisterTypeLib

This function removes type library information from the system registry.

VarBoolFromCy

This function converts variant data types to BOOL from CURRENCY.

VarBoolFromDate

This function converts variant data types to BOOL from DATE.

VarBoolFromDec

This function converts variant data types to BOOL from DECIMAL.

VarBoolFromDisp

This function converts variant data types to BOOL from IDispatch.

VarBoolFromI2

This function converts variant data types to BOOL from short.

VarBoolFromI4

This function converts variant data types to BOOL from long.

VarBoolFromR4

This function converts variant data types to BOOL from float.

VarBoolFromR8

This function converts variant data types to BOOL from double.

VarBoolFromStr

This function converts variant data types to BOOL from OLECHAR.

VarBoolFromUI1

This function converts variant data types to BOOL from unsigned char.

VarBstrFromBool

This function converts variant data types to BSTR from BOOL.

VarBstrFromCy

This function converts variant data types to BSTR from CURRENCY.

VarBstrFromDate

This function converts variant data types to BSTR from DATE.

VarBstrFromDec

This function converts variant data types to BSTR from DECIMAL.

VarBstrFromDisp

This function converts variant data types to BSTR from IDispatch.

VarBstrFromI2

This function converts variant data types to BSTR from short.

VarBstrFromI4

This function converts variant data types to BSTR from long.

VarBstrFromR4

This function converts variant data types to BSTR from float.

VarBstrFromR8

This function converts variant data types to BSTR from double.

VarBstrFromUI1

This function converts variant data types to BSTR from BYTE.

VarCyFromBool

This function converts variant data types to CURRENCY from BOOL.

VarCyFromDate

This function converts variant data types to CURRENCY from DATE.

VarCyFromDec

This function converts variant data types to CURRENCY from DECIMAL.

VarCyFromDisp

This function converts variant data types to CURRENCY from IDispatch.

VarCyFromI2

This function converts variant data types to CURRENCY from short.

VarCyFromI4

This function converts variant data types to CURRENCY from long.

VarCyFromR4

This function converts variant data types to CURRENCY from float.

VarCyFromR8

This function converts variant data types to CURRENCY from double.

VarCyFromStr

This function converts variant data types to CURRENCY from OLECHAR.

VarCyFromUI1

This function converts variant data types to CURRENCY from BYTE.

VarDateFromBool

This function converts variant data types to DATE from BOOL.

VarDateFromCy

This function converts variant data types to date from CURRENCY.

VarDateFromDec

This function converts variant data types to DATE from DECIMAL.

VarDateFromDisp

This function converts variant data types to DATE from IDispatch.

VarDateFromI2

This function converts variant data types to DATE from short.

VarDateFromI4

This function converts variant data types to DATE from long.

VarDateFromR4

This function converts variant data types to DATE from float.

VarDateFromR8

This function converts variant data types to DATE from double.

VarDateFromStr

This function converts variant data types to DATE from OLECHAR.

VarDateFromUdate

This function packs a date.

VarDateFromUI1

This function converts variant data types to DATE from BYTE.

VarDecFromBool

This function converts variant data types to DECIMAL from BOOL.

VarDecFromCy

This function converts variant data types to DECIMAL from CURRENCY.

VarDecFromDate

This function converts variant data types to DECIMAL from DATE.

VarDecFromDisp

This function converts variant data types to DECIMAL from IDispatch.

VarDecFromI2

This function converts variant data types to DECIMAL from short.

VarDecFromI4

This function converts variant data types to DECIMAL from long.

VarDecFromR4

This function converts variant data types to DECIMAL from float.

VarDecFromR8

This function converts variant data types to DECIMAL from double.

VarDecFromStr

This function converts variant data types to DECIMAL from OLECHAR.

VarDecFromUI1

This function converts variant data types to DECIMAL from BYTE.

VarI2FromBool

This function converts variant data types to short from BOOL.

VarI2FromCy

This function converts variant data types to short from CURRENCY.

VarI2FromDate

This function converts variant data types to short from DATE.

VarI2FromDec

This function converts variant data types to Short from DECIMAL.

VarI2FromDisp

This function converts variant data types to short from IDispatch.

VarI2FromI4

This function converts variant data types to short from long.

VarI2FromR4

This function converts variant data types to short from float.

VarI2FromR8

This function converts variant data types to short from double.

VarI2FromStr

This function converts variant data types to short from OLECHAR.

VarI2FromUI1

This function converts variant data types to short from BYTE.

VarI4FromBool

This function converts variant data types to long from BOOL.

VarI4FromCy

This function converts variant data types to long from CURRENCY.

VarI4FromDate

This function converts variant data types to long from DATE.

VarI4FromDec

This function converts variant data types to long from DECIMAL.

VarI4FromDisp

This function converts variant data types to long from IDispatch.

VarI4FromI2

This function converts variant data types to long from short.

VarI4FromR4

This function converts variant data types to long from float.

VarI4FromR8

This function converts variant data types to long from double.

VarI4FromStr

This function converts variant data types to long from OLECHAR.

VarI4FromUI1

This function converts variant data types to long from BYTE.

VariantChangeType

This function converts a variant from one type to another.

VariantChangeTypeEx

This function converts a variant from one type to another, using a LCID.

VariantClear

This function clears a variant.

VariantCopy

This function frees the destination variant and makes a copy of the source variant.

VariantCopyInd

This function frees any existing content of the destination variant and makes a copy of the source VARIANT and VARIANTARG, performing the necessary indirection if the source is specified to be VT_BYREF.

VariantInit

This function initializes a variant.

VariantTimeToSystemTime

This function converts the variant representation of time to system time values.

VarNumFromParseNum

This function converts the parsed number to a number of the VARIANT and VARIANTARG type.

VarParseNumFromStr

This function parses a string and creates a type-independent description of the number it represents.

VarR4FromBool

This function converts variant data types to float from BOOL.

VarR4FromCy

This function converts variant data types to float from CURRENCY.

VarR4FromDate

This function converts variant data types to float from DATE.

VarR4FromDec

This function converts variant data types to float from DECIMAL.

VarR4FromDisp

This function converts variant data types to float from IDispatch.

VarR4FromI2

This function converts variant data types to float from short.

VarR4FromI4

This function converts variant data types to float from long.

VarR4FromR8

This function converts variant data types to float from double.

VarR4FromStr

This function converts variant data types to float from OLECHAR.

VarR4FromUI1

This function converts variant data types to float from BYTE.

VarR8FromBool

This function converts variant data types to double from BOOL.

VarR8FromCy

This function converts variant data types to double from CURRENCY.

VarR8FromDate

This function converts variant data types to double from DATE.

VarR8FromDec

This function converts variant data types to double from DECIMAL.

VarR8FromDisp

This function converts variant data types to double from IDispatch.

VarR8FromI2

This function converts variant data types to double from short.

VarR8FromI4

This function converts variant data types to double from long.

VarR8FromR4

This function converts variant data types to double from float.

VarR8FromStr

This function converts variant data types to double from OLECHAR.

VarR8FromUI1

This function converts variant data types to double from unsigned char.

VarUdateFromDate

This function converts a time and date converted from variant format to MS-DOS format.

VarUI1FromBool

This function converts variant data types to BYTE from BOOL.

VarUI1FromCy

This function converts variant data types to BYTE from CURRENCY.

VarUI1FromDate

This function converts variant data types to BYTE from DATE.

VarUI1FromDec

This function converts variant data types to BYTE from DECIMAL.

VarUI1FromDisp

This function converts variant data types to BYTE from IDispatch.

VarUI1FromI2

This function converts variant data types to BYTE from short.

VarUI1FromI4

This function converts variant data types to BYTE from long.

VarUI1FromR4

This function converts variant data types to BYTE from float.

VarUI1FromR8

This function converts variant data types to BYTE from double.

VarUI1FromStr

This function converts variant data types to BYTE from BSTR.

VectorFromBstr

This function returns a vector, assigning each character in the BSTR to an element of the vector.

See Also

Reference

Automation Reference