VariantInit

Void VariantInit( 
  VARIANTARG FAR*  pvarg  
);
 

Initializes a variant.

Parameter

pvarg
Pointer to the VARIANTARG that will be initialized.

Comments

The VariantInit function initializes the VARIANTARG by setting the vt field to VT_EMPTY. Unlike VariantClear, this function does not interpret the current contents of the VARIANTARG. Use VariantInit to initialize new local variables of type VARIANTARG (or VARIANT).

Example

for(i = 0; i < celt; ++i)
    VariantInit(&rgvar[i]);

QuickInfo

  Windows NT: Use version 3.1 and later.
  Windows: Use Windows 95 and later.
  Header: Declared in oleauto.h.
  Import Library: Link with oleaut32.lib.