共用方式為


_variant_t::ChangeType

void ChangeType( VARTYPE vartype**, const _variant_t*** pSrc = NULL ) throw( _com_error );

Parameters

vartype

the VARTYPE for this _variant_t object

pSrc

a pointer to the _variant_t object to be converted. If this value is NULL, conversion is done in place.

Remarks

This member function converts a _variant_t object into the indicated VARTYPE. If pSrc is NULL, the conversion is done in place, otherwise this _variant_t object is copied from pSrc and then converted.

_variant_t Overview

END Microsoft Specific