Top  Previous  Next

int _stdcall


   IN  PACKAGE_HANDLE               hPkg,

   OUT LPWSTR                       WorkKey,

   IN  DWORD                        WorkKeyLen )

Provides an image of the virtual registry as contained in the virtual package.


hPkg [in]

Virtual application package handle, returned by PackageOpen.

WorkKey [out]

Buffer to receive the name of the virtual registry key's image, relative to HKEY_CURRENT_USER. This key will be deleted when calling PackageClose.

WorkKeyLen [in]

Indicates the size of the WorkKey buffer, in characters.

Return Value

Returns APIRET_SUCCESS if successful, or APIRET_VIRTREG_DEPLOY_ERROR if the virtual registry key could not be written.

APIRET_INSUFFICIENT_BUFFER is returned when the buffer size provided for WorkKey is not sufficient.


To apply changes to the virtual registry, don't forget to call VirtRegSaveWorkKey before using PackageSave.