;

PDA

Click to See Complete Forum and Search --> : [RESOLVED] Combobox not setting value?


dniezby
04-08-2007, 05:34 PM
I'm having an issue getting the chosen value of a combobox.

I want to assign the chosen value to a variable so here is what I did.

In the onChange option.

shipmethod = this.getValue();

Isn't that supposed to work?

I set up a textbox with the variable shipmethod to test it and it's not working.

I've also tried:

shipmethod = this.getSelectedItem();

Any thoughts?

2 items in combobox (eMail, snailMail)

blanius
04-08-2007, 11:27 PM
A combobox is itself a movieclip that resides in the main timeline. so you'd need to refer to a text box on the main movie via it's path i.e. _parent or _root

dniezby
04-09-2007, 01:38 PM
I've tried a number of things and still can't get the value from the combobox.

My combobox is inside another movie clip called FORM. I can't explain it.

I've tried everything. I'm sure it's my syntax.

Here is my actual comboboxes path. _root.form.combobox1

Chris_Seahorn
04-09-2007, 02:38 PM
Attached

dniezby
04-09-2007, 08:01 PM
I figured out what I was doing wrong.

My combobox is inside another movieclip. When I was referring to it in the onChanged box I was using:

txt1.text = this.getValue();

When I removed the "this" it worked. So now I'm back on track.

---------------
Chris? Is that you? Long time no see.
I'll also take a look at your file and see what you posted too. Maybe there is another technique that I could use.