Session.Console is always null (x86 and x64 app)

Discussion about using the VirtualBox API, Tutorials, Samples.
Post Reply
eivanov
Posts: 1
Joined: 9. May 2019, 20:42

Session.Console is always null (x86 and x64 app)

Post by eivanov »

I'm creating the application with the following C# code:

Code: Select all

VirtualBox.VirtualBox box = new VirtualBox.VirtualBox();
Session session = new Session();
var rootPc = box.FindMachine("Windows Server 2016");
rootPc.LockMachine(session, LockType.LockType_Write);

var pc = session.Machine;
var console = session.Console;
console object is always null. I have tried x86 and x64 apps. Different settings for interop assemply. But regardless console is always null. The same results in powershell (x86 and x64).

VirtualBox version is 6.0.6 r130049 (x64). The same was before upgrade on 5.20.* version
OS is Windows 10 Version 1607 (OS Build 14393.2906).

What could be the reason of this behavior.

Thank you.
Post Reply