<div dir="ltr"><div><div>I tried to use this function in VMM/VMMAll/TMAll.cpp, but when i compile, i receive this: ‘CFGMR3GetRoot’ was not declared in this scope<br></div>I added #include <VBox/vmm/cfgm.h, but atill have this error.<br>
</div><div>Any ideas? I tried also to include <stdio.h> for others achievements, but i recieve an error too (however in others .cpp files i can use stdio.h without any problems): i don't understand why<br></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">2014-06-06 14:51 GMT+02:00 Frank Mehnert <span dir="ltr"><<a href="mailto:frank.mehnert@oracle.com" target="_blank">frank.mehnert@oracle.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Johannes,<br>
<div><div class="h5"><br>
On Friday 06 June 2014 14:46:46 Johannes DeWitt wrote:<br>
> I, i need to use come IMachine methods in source code. For example, if a<br>
> want to use the GetSettingsFilePath() function (used in<br>
> tstVBoxAPIXPCOM.cpp) in a cpp file of the source code, for example in a cpp<br>
> file in /src/VBox/VMM/VMMAll/, how can i do it?<br>
> And which headers files i need to include?<br>
<br>
</div></div>that's actually not the intended way to use !VirtualBox. VMM and Main<br>
are strictly separated, and in particular the IMachine code you are<br>
talking about lives in VBoxSVC while the VMM code lives in the VBoxSVC<br>
client (either the VirtualBox process or the VBoxHeadless process).<br>
<br>
Inside VMM you should always have a pRoot handle,<br>
<br>
  pRoot = CFGMR3GetRoot(pVM);<br>
<br>
Using this pRoot handle you can access the CFGM tree for that particular<br>
VM.<br>
<br>
Kind regards,<br>
<br>
Frank<br>
--<br>
Dr.-Ing. Frank Mehnert | Software Development Director, VirtualBox<br>
ORACLE Deutschland B.V. & Co. KG | Werkstr. 24 | 71384 Weinstadt, Germany<br>
<br>
Hauptverwaltung: Riesstr. 25, D-80992 München<br>
Registergericht: Amtsgericht München, HRA 95603<br>
Geschäftsführer: Jürgen Kunz<br>
<br>
Komplementärin: ORACLE Deutschland Verwaltung B.V.<br>
Hertogswetering 163/167, 3543 AS Utrecht, Niederlande<br>
Handelsregister der Handelskammer Midden-Niederlande, Nr. 30143697<br>
Geschäftsführer: Alexander van der Ven, Astrid Kepper, Val Maher<br>
<br>
_______________________________________________<br>
vbox-dev mailing list<br>
<a href="mailto:vbox-dev@virtualbox.org">vbox-dev@virtualbox.org</a><br>
<a href="https://www.virtualbox.org/mailman/listinfo/vbox-dev" target="_blank">https://www.virtualbox.org/mailman/listinfo/vbox-dev</a><br>
</blockquote></div><br></div>