PDA

View Full Version : comboBox_mc rotation


xcaliber
08-24-2004, 08:36 PM
Hello,

I have a comboBox that has different degree labels that allows the user to rotate a movieClip. I have the following code on the first frame, and I have _rotation, 45; in the date cell for the comboBox.

Can anyone look at this code, and tell me what's wrong or give advice.(I am using MX 2004 Pro)





listenerObject = new Object();
listenerObject.change = function(eventObject)
{
var choose = myCB.selectedItem;
myMC.setProperty(choose.data)

};
myCB.addEventListener("change", listenerObject);




Thanks,

xcaliber

deQue
08-25-2004, 01:02 AM
Well, you're using the wrong refrencing.
Here's how it should look:

listenerObject = new Object();
listenerObject.change = function(eventObj)
{
var chosenData = eventObj.selectedItem.data;
myMC.setProperty(chosenData)

};
myCB.addEventListener("change", listenerObject);

xcaliber
08-25-2004, 02:29 PM
Thanks for pointing me in the right direction deQue,
I will give it a shot.

xcaliber