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

# CoGetStandardMarshal(3w)

## NAME

**CoGetStandardMarshal** (OLE32.@)

## SYNOPSIS

HRESULT CoGetStandardMarshal\
  (\
   REFIID     *riid*,\
   IUnknown\*  *pUnk*,\
   DWORD      *dwDestContext*,\
   LPVOID     *pvDestContext*,\
   DWORD      *mshlflags*,\
   LPMARSHAL\* *ppMarshal*\
  )

## DESCRIPTION

Gets or creates a standard marshal object.

## PARAMS

*riid* **\[In\]**  Interface identifier of the *pUnk* object.

*pUnk* **\[In\]**  Optional. Object to get the marshal object for.

*dwDestContext* **\[In\]**  Destination. Used to enable or disable optimizations.

*pvDestContext* **\[In\]**  Reserved. Must be **NULL**.

*mshlflags* **\[In\]**  Flags affecting the marshaling process.

*ppMarshal* **\[Out\]**  Address where marshal object will be stored.

## RETURNS

**Success:** **S\_OK**.

**Failure:** **HRESULT** code.

## NOTES

The function retrieves the **IMarshal** object associated with an object if that object is currently an active stub, otherwise a new marshal object is created.

## IMPLEMENTATION

Declared in **"objbase.h"**.

Implemented in **"dlls/ole32/marshal.c"**.

Debug channel **"ole"**.
