Not able to start VMs in Virtualbox – Ubuntu 12.10

After installing virtualbox you get the following message:

WARNING: The character device /dev/vboxdrv does not exist.
Please install the virtualbox-ose-dkms package and the appropriate
headers, most likely linux-headers-generic.

You will not be able to start VMs until this problem is fixed.

To fix it run the following commands:

sudo apt-get install build-essential linux-headers-`uname -r`
sudo dpkg-reconfigure virtualbox-dkms
sudo dpkg-reconfigure virtualbox

BlackBerry 10 Cascades – console.log() and qDebug() output

This snippet of code will allow you to see the output of qDebug and console.log from the Momentics IDE when developing for BlackBerry 10.

First we need to add this function to the main.cpp file:

void myMessageOutput(QtMsgType type, const char* msg){
fprintf(stdout, "%s\n", msg);

Inside our main() function, add this:

//Message Handler

Now you will be able to see the output in the IDE while debugging your application, make sure to comment the qInstallMsgHandler line before exporting the Release version of your application.