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

# PFPlatformLocalStorageSetHandlers

> Sets the storage event handlers. If custom storage handlers are not set, a default implementation based on cstdio and std::fstream objects will be used.

Sets the storage event handlers. If custom storage handlers are not set, a default implementation based on cstdio and std::fstream objects will be used.

## Syntax

```cpp theme={null}
HRESULT PFPlatformLocalStorageSetHandlers(  
    PFLocalStorageHooks* hooks  
)  
```

### Parameters

**`hooks`**   [PFLocalStorageHooks\*](/services/playfab/api-references/c/pfplatform/structs/pflocalstoragehooks)

Custom local storage hooks to be used by the SDK.

### Return value

Type: HRESULT

Result code for this API operation.

## Remarks

Must be called before PFInitialize.

## Requirements

**Header:** PFPlatform.h

## See also

[PFPlatform members](/services/playfab/api-references/c/pfplatform/pfplatform_members)


## Related topics

- [Services C API overview - PFPlatform.h](/services/playfab/api-references/c/pfplatform/pfplatform_members.md)
- [XblLocalStorageSetHandlers](/reference/live/xsapi-c/platform_c/functions/xbllocalstoragesethandlers.md)
- [PFLocalStorageHooks](/services/playfab/api-references/c/pfplatform/structs/pflocalstoragehooks.md)
- [XblLocalStorageClearHandler](/reference/live/xsapi-c/platform_c/functions/xbllocalstorageclearhandler.md)
- [XblLocalStorageReadHandler](/reference/live/xsapi-c/platform_c/functions/xbllocalstoragereadhandler.md)
