easy question

ok, im a newbie in mel script, so please don't laugh

ok, i got a ball and a camera aimed to the ball.
i got a measure distance tool between them, each locator parented to the cam and the ball.

I would like to constrain the center of interest of the camera to the variable "distance" from my measure tool.

so i think i have to right click on the center of interest in attribut editor of the cam and create a new expression.

and so what is the script of this new expression?
i tried
cameraShape1.centerOfInterest=mesure.Distance

but it seems to be more difficult

I'm a stranger to mel too and barely know how to write a random.
But why script this? You could choose a two or threepoint camera and parent the camera and COI to the two locators.
I'd have the right effect I believe.
Maos.

i tried, but i don't know how to parent COI to something else...

Use the outliner, select the "camera view"-node and mmbdrag it onto the measure locator it's the same as all parenting...