Cursor Control in Photon App

I am trying to turn on/off the mouse pointer in a touch screen app, I have
used the example in qdn.qnx.com knowledge base (9533). When I call the
function described, my application hangs up ?? Am I missing something ?

TIA

Martin