Microsoft.Xbox.Wrappers.XGameSave.Provider.Save
Saves data to the specified blob (file) within the specified container.Syntax
Parameters
containerName _In_Type: std::string The name of the container. blobName _In_
Type: std::string The name of the blob. dataSize _In_
Type: size_t The amount of data to write to the blob. This size is limited to a maximum of 16 MB (GS_MAX_BLOB_SIZE). blobData _In_
Type: uint8_t* A pointer to the bytes to write to the blob.
Return value
Type: HRESULT This method returns S_OK upon success, and the following HRESULT codes upon failure:- GS_INVALID_CONTAINER_NAME
- GS_OUT_OF_LOCAL_STORAGE
- GS_UPDATE_TOO_BIG
- GS_QUOTA_EXCEEDED
- GS_HANDLE_EXPIRED
Example
The following code example demonstrates how to use the Save function.Remarks
You must call the Initialize method before you can call any other method from theProvider class.
To initialize the save game wrapper, and synchronize all of the containers for the specified user, call Initialize.
To load the data from the given blob, from within the specified container, call Load.
Requirements
Header: xgamesavewrappers.hpp Supported platforms: Windows, XBOX One family consoles and XBOX Series consolesSee also
Microsoft.Xbox.Wrappers.XGameSave.ProviderXGameSave wrapper members
Load
