Collapse All
Parallels Virtualization SDK
ContentsIndex
PreviousUpNext
PrlVm_StartEx Function
PHT_VIRTUAL_MACHINE

Starts the specified virtual machine using the specified mode (see the PRL_VM_START_MODE enumeration).

Syntax
PRL_HANDLE PrlVm_StartEx(
    PRL_HANDLE hVm, 
    PRL_UINT32 nStartMode, 
    PRL_UINT32 nReserved
);
File

PrlApiVm.h

Parameters

hVm
A handle of type PHT_VIRTUAL_MACHINE identifying the virtual machine.
nStartMode
Virtual machine start mode.
nReserved
This is a reserved parameter.

Returns

A handle of type PHT_JOB containing the results of this asynchronous operation or PRL_INVALID_HANDLE if there's not enough memory to instantiate the job object.

Remarks

Use this function instead of the PrlVm_Start function to start the virtual machine in a normal or safe mode. Other modes may be added in the future. 

If VM is starting in PSM_VM_START_FOR_COMPACT mode then flags (third argument) have to be equal PRL_HARD_DISK_IFACE_MASK enum. 

To get the return code from the PHT_JOB object, use the PrlJob_GetRetCode function. Possible values are: 

PRL_ERR_INVALID_ARG - invalid handle or start mode of virtual machine. 

PRL_ERR_SUCCESS - function completed successfully. 

Links
© 2021 Parallels International GmbH. All rights reserved.