running javascripts in chtmleditctrl

Hi,
I want to know can I run javascript in ChtmlEditCtrl when it is in edit mode??Actually,I am able to run java script in inherit mode(non edit mode) but in this mode I am unable to capture event(like mose down or up) in this ChtmlEditctrl.That's why I want to run scripts in ChtmlEditCtrl.
Thanks...