> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# OpenSharedHandleByName

> Name と Access を使用して、共有リソース、共有ヒープ、および共有フェンスのハンドルを開きます。

Name と Access を使用して、共有リソース、共有ヒープ、および共有フェンスのハンドルを開きます。

## 構文

```cpp theme={null}
HRESULT OpenSharedHandleByName(
    LPCWSTR Name,
    DWORD Access,
    HANDLE  pNTHandle
)
```

### パラメーター

*Name \[in]*\
型: LPCWSTR

[ID3D12Device::CreateSharedHandle](https://docs.xbox.com/ja-jp/reference/graphics/d3d12/interfaces/id3d12device/methods/id3d12device_createsharedhandle_public.md) の呼び出しで *Name* パラメーターとして省略可能に渡された名前。

*Access*\
型: DWORD

[ID3D12Device::CreateSharedHandle](https://docs.xbox.com/ja-jp/reference/graphics/d3d12/interfaces/id3d12device/methods/id3d12device_createsharedhandle_public.md) の呼び出しで *Access* パラメーターに指定されたアクセス レベル。

*pNTHandle \[out]*\
型: HANDLE \*

共有ハンドルへのポインター。

### 戻り値

型: HRESULT

このメソッドは [Direct3D 12 の戻りコード](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/d3d12-graphics-reference-returnvalues) のいずれかを返します。

## 要件

**ヘッダー:** d3d12\_xs.h または d3d12\_x.h\
**ライブラリ:** d3d12\_xs.lib または d3d12\_x.lib\
**サポートされているプラットフォーム**: XBOX Series 本体および XBOX One ファミリ

## 関連項目

[ID3D12Device](https://docs.xbox.com/ja-jp/reference/graphics/d3d12_x/interfaces/id3d12device/id3d12device.md)


## Related topics

- [OpenSharedHandle](https://docs.xbox.com/ja-jp/reference/graphics/d3d12/interfaces/id3d12device/methods/id3d12device_opensharedhandle_public.md)
- [OpenWaitHandle](https://docs.xbox.com/ja-jp/reference/input/gameinput/interfaces/IGameInputDispatcher/methods/igameinputdispatcher_openwaithandle.md)
- [Get Player Shared Secrets](https://docs.xbox.com/api-reference/authentication/get-player-shared-secrets.md)
- [Update Player Shared Secret](https://docs.xbox.com/api-reference/authentication/update-player-shared-secret.md)
- [Create Player Shared Secret](https://docs.xbox.com/api-reference/authentication/create-player-shared-secret.md)
