ApplicationData.SetVersionAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Sets the version number of the application data in the app data store.
public:
virtual IAsyncAction ^ SetVersionAsync(unsigned int desiredVersion, ApplicationDataSetVersionHandler ^ handler) = SetVersionAsync;
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncAction SetVersionAsync(uint32_t const& desiredVersion, ApplicationDataSetVersionHandler const& handler);
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncAction SetVersionAsync(uint desiredVersion, ApplicationDataSetVersionHandler handler);
function setVersionAsync(desiredVersion, handler)
Public Function SetVersionAsync (desiredVersion As UInteger, handler As ApplicationDataSetVersionHandler) As IAsyncAction
Parameters
- desiredVersion
-
UInt32
unsigned int
uint32_t
The new version number.
- handler
- ApplicationDataSetVersionHandler
The set version event handler.
Returns
An object that is used to manage the asynchronous set version operation.
- Attributes
Remarks
Versioning enables you to change the application data format used in a future release of your app without causing compatibility problems with previous releases of your app. The app checks the version of the data in the data store, and if it is less than the version the app expects, the app should update the application data to the new format and update the version.
It is strongly recommended that you use sequential and incrementing version numbers, starting at 1.