tracking problem

hi there,

I am writing a script that constructs and renders scenes out of xml scripts. everything seems to work fine, besides that I cannot set the orientation of the camera properly. I have tried to use the track method, but I am only getting an error message saying that tracking is not allowed.
Since I am not using logicBricks, I cannot employ the setOrientation method of controller objects.
I am sure there must be some other method that does the same + would be really grateful for any suggestions… :o