Collapse All
Parallels Virtualization SDK
ContentsIndex
PreviousUpNext
PrlUsrCfg_SetDefaultVmFolder Function
PHT_USER_PROFILE

Allows to set a default virtual machine folder for the user.

Syntax
PRL_RESULT PrlUsrCfg_SetDefaultVmFolder(
    PRL_HANDLE hUserProfile, 
    PRL_CONST_STR sNewDefaultVmFolder
);
File

PrlApiDisp.h

Parameters

hUserProfile
A handle of type PHT_USER_PROFILE identifying the user.
sNewDefaultVmFolder
Name and path of the folder to set as default virtual machine folder for the user. The folder must already exist on the host.

Returns

PRL_RESULT. Possible values: 

PRL_ERR_INVALID_ARG - invalid handle or null pointer was passed. 

PRL_ERR_SUCCESS - function completed successfully. 

 

Remarks

A Parallels Service has a default virtual machine directory (the directory where new virtual machines are created). Individual users can have their own default virtual machine directories if needed. If a user has its own virtual machine directory set up, it takes precedence over the Parallels Service default. To set a default directory for a user, first call the PrlSrv_UserProfileBeginEdit function to mark the beginning of the operation. Then call the PrlUsrCfg_SetDefaultVmFolder function to set the new default virtual machine folder. Finally, call the PrlSrv_UserProfileCommit function to save your changes.

Links
© 2021 Parallels International GmbH. All rights reserved.