---
name: "VariantChangeType"
section: "3w"
platform: "linux"
package: "libwine-dev"
version: "1.4.1-4"
release: "Debian 7 (Wheezy)"
platforms: ["linux"]
url: "https://new.carta.tech/VariantChangeType"
---

# VariantChangeType(3w)

## NAME

**VariantChangeType** (OLEAUT32.12)

## SYNOPSIS

HRESULT VariantChangeType\
  (\
   VARIANTARG\* *pvargDest*,\
   VARIANTARG\* *pvargSrc*,\
   USHORT      *wFlags*,\
   VARTYPE     *vt*\
  )

## DESCRIPTION

Change the type of a variant.

## PARAMS

*pvargDest* **\[Out\]**  Destination for the converted variant.

*pvargSrc* **\[Out\]**  Source variant to change the type of.

*wFlags* **\[In\]**  **VARIANT\_** flags from **"oleauto.h"**.

*vt* **\[In\]**  Variant type to change *pvargSrc* into.

## RETURNS

**Success:** **S\_OK**. *pvargDest* contains the converted value.

**Failure:** An **HRESULT** error code describing the failure.

## NOTES

The **LCID** used for the conversion is **LOCALE\_USER\_DEFAULT**. See **[VariantChangeTypeEx(3w)](/VariantChangeTypeEx/3w.md)**.

## IMPLEMENTATION

Declared in **"oleauto.h"**.

Implemented in **"dlls/oleaut32/variant.c"**.

Debug channel **"variant"**.
