Skip to main content

XGameSaveCreateUpdate

Creates an update which will later be submitted by calling XGameSaveSubmitUpdate.

Syntax

Parameters

container   _In_
Type: XGameSaveContainerHandle
Handle to the XGameSaveContainer to be updated. containerDisplayName   _In_z_
Type: char*
Display name for the container to be updated. updateContext   _Outptr_result_nullonfailure_
Type: XGameSaveUpdateHandle*
Handle to the XGameSaveUpdate to be created.

Return value

Type: HRESULT Function result.

Remarks

This function isn’t safe to call on a time-sensitive thread. For more information, see Time-sensitive threads.
The storage portion of this API is designed to easily transfer data from the game to persisted storage in a safe, reliable and transactional manner. We want to make sure the backing data for a container is always consistent and as such we want the whole operation to succeed or fail atomically. We don’t want to have a partial update where some blob data is inconsistent with other data within the container. In order to do this we provide an update context that blob writes and deletes are submitted to and when that is ready the whole context is submitted. In practice this looks like the following: An XGameSaveUpdate will be filled with Write and Delete actions to be carried out on blobs within the container by way of XGameSaveSubmitBlobWrite and XGameSaveSubmitBlobDelete. An update is completed by calling XGameSaveSubmitUpdate. When you have finished with an XGameSaveUpdate close it with XGameSaveCloseUpdate. The following C++ sample demonstrates a synchronous XGameSave update.
The following C++ sample demonstrates an asynchronous XGameSave update.

Requirements

Header: XGameSave.h Library: xgameruntime.lib Supported platforms: Windows, XBOX One family consoles and XBOX Series consoles

Conceptual documentation

See also

XGameSave
XGameSaveSubmitBlobWrite
XGameSaveSubmitBlobDelete
XGameSaveSubmitUpdate
XGameSaveCloseUpdate Debugging Game Saves
Last modified on August 20, 2026