# Second set of eyes trouble with a simple code

**URL:** <https://forum.kirupa.com/t/second-set-of-eyes-trouble-with-a-simple-code/170186>\
**Category:** flash\
**Created:** [November 23, 2005, 3:56pm UTC](https://forum.kirupa.com/t/second-set-of-eyes-trouble-with-a-simple-code/170186 "2005-11-23T15:56:49Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![garyzero](https://avatars.discourse-cdn.com/v4/letter/g/71c47a/32.png) [@garyzero](https://forum.kirupa.com/u/garyzero)\
**Post date:** [November 23, 2005, 3:56pm UTC](https://forum.kirupa.com/t/second-set-of-eyes-trouble-with-a-simple-code/170186/1 "2005-11-23T15:56:49Z")

</div>

Hi,

Can some one l;ook this code over and see if there is a mistake that will not allow for the combobox to have the text in it be sized to 10 point. I have done 2 other just like this and they work.

//Tabbing through fields  
name\_txt.tabIndex = 1;  
phone\_txt.tabIndex = 2;  
time\_txt.tabIndex = 3;  
zip\_txt.tabIndex = 4;  
submit\_bt.tabIndex = 5;  
focusManager.defaultPushButton = submit\_bt;

//Style for the Input Fields and Combo Box  
zzFStyleFormat = new FStyleFormat();  
zzFStyleFormat.background = 0x003333;  
zzFStyleFormat.selection = 0x006666;  
zzFStyleFormat.textColor = 0xCCCCCC;  
zzFStyleFormat.textSize = 10;  
zzFStyleFormat.arrow = 0xFFFFFF;  
zzFStyleFormat.face = 0x009999;  
zzFStyleFormat.scrollTrack = 0x000000;  
zzFStyleFormat.shadow = 0x006666;  
zzFStyleFormat.darkshadow = 0x003333;  
zzFStyleFormat.highlight = 0x00CCCC;  
zzFStyleFormat.highlight3D = 0x006666;  
//Apply style to Input Fields and Combo Box  
zzFStyleFormat.addListener(time\_txt);  
zzFStyleFormat.addListener(name\_txt);  
zzFStyleFormat.addListener(phone\_txt);  
zzFStyleFormat.addListener(zip\_txt);

//Combo Box  
// populate the combobox  
zzmyLabels = new Array (“Select”,“Morning”,“Afternoon”,“Evening”);  
for (zz=0;zz\<zzmyLabels.length;zz++) {  
time\_txt.addItem (zzmyLabels[zz]) ;  
}  
// function to display the selection  
function zzcomboDisplay (component) {  
time\_txt = component.getSelectedItem().label ;  
}  
// We assign the function to the combobox  
time\_txt.setChangeHandler (“zzcomboDisplay”) ;

//input text field lables  
name\_txt.text = “Enter your name”;  
phone\_txt.text = “Phone number”;  
zip\_txt.text = “Zip”;

//clear input text field onFocus, if something typed in don’t clear input text field, if nothing typed in rename input text field onFocusKill  
name\_txt.onSetFocus = function() {  
if (name\_txt.text == “Enter your name”) {  
name\_txt.text = “”;  
}  
};  
name\_txt.onKillFocus = function() {  
if (name\_txt.text == “”) {  
name\_txt.text = “Enter your name”;  
}  
};  
phone\_txt.onSetFocus = function() {  
if (phone\_txt.text == “Phone number”) {  
phone\_txt.text = “”;  
}  
};  
phone\_txt.onKillFocus = function() {  
if (phone\_txt.text == “”) {  
phone\_txt.text = “Phone number”;  
}  
};  
zip\_txt.onSetFocus = function() {  
if (zip\_txt.text == “Zip”) {  
zip\_txt.text = “”;  
}  
};  
zip\_txt.onKillFocus = function() {  
if (zip\_txt.text == “”) {  
zip\_txt.text = “Zip”;  
}  
};

//Submits data from fields in form  
submit\_bt.onRelease = function() {  
subject = “Cover What’s Yours”;  
recipient = “”;  
redirect = “”;  
loadVariables(“ccMailer.jsp”, “”, “POST”);  
gotoAndStop(“thanks”);  
};

stop();
