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

# SHAllocShared(3w)

## NAME

**SHAllocShared** (SHLWAPI.7)

## SYNOPSIS

HANDLE SHAllocShared\
  (\
   LPCVOID *lpvData*,\
   DWORD   *dwSize*,\
   DWORD   *dwProcId*\
  )

## DESCRIPTION

Create a block of sharable memory and initialise it with data.

## PARAMS

*lpvData* **\[In\]**  Pointer to data to write.

*dwSize* **\[In\]**  Size of data.

*dwProcId* **\[In\]**  Id of process owning data.

## RETURNS

**Success:** A shared memory handle

**Failure:** **NULL**.

## NOTES

Ordinals **7-11** provide a set of calls to create shared memory between a group of processes. The shared memory is treated opaquely in that its size is not exposed to clients who map it. This is accomplished by storing the size of the map as the first **DWORD** of mapped data, and then offsetting the view pointer returned by this size.

## IMPLEMENTATION

Not declared in a Wine header. The function is either undocumented, or missing from Wine.

Implemented in **"dlls/shlwapi/ordinal.c"**.

Debug channel **"shell"**.
