# Problems with textstring from combobox

**URL:** <https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097>\
**Category:** flash\
**Created:** [May 5, 2003, 7:29am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097 "2003-05-05T07:29:09Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![mooler](https://avatars.discourse-cdn.com/v4/letter/m/b4bc9f/32.png) [@mooler](https://forum.kirupa.com/u/mooler)\
**Post date:** [May 5, 2003, 7:29am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097/1 "2003-05-05T07:29:09Z")

</div>

Hello

After searching forever for a sollution for this problem I turn to the almighty kirupa for help.

I´ll attach the fla.

I have 2 comboboxed and I want the value from the boxes to go into a textfield.

Now the cb containing numbers is no problem it works fine. But the cb with letters in it (XL,L,M,S) won´t show.

Now I figure I have to “process” the letters in some way to get the swf to understand them but I haven´t got a clue how to do that?

If someone please could help it´s greatly appreciated.

Just in case it´s enough with the code I´ll attach it as well so you don´t have to dl the fla.

[AS]function onSubmit() {  
var quantity = “”;  
var size = “”;  
// Gather the information from comboboxes  
quantity = quantity\_cb.getValue();  
size = size\_cb.getValue();

```
if (quantity &gt; 0); {

message_txt.text = "You picked" + newline;
message_txt.text += "Size" + " " + size + newline;
message_txt.text += "Quantity" + " " + quantity;
}

```

}{[/AS]

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 5, 2003, 8:07am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097/2 "2003-05-05T08:07:16Z")

</div>

the instance name is wrong…

in the script you have size\_cb and in the instance name of the component you have size\_cn. 😉

by the way…

```auto
message_txt.text = "You picked
Size "+size+"
Quantity "+quantity;

```

isn’t that easier? :-\

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 5, 2003, 8:23am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097/3 "2003-05-05T08:23:43Z")

</div>

Man did I really do that!??

Sorry for that really clumsy of me, can´t believe I missed that…well.

Right now im at a comp without flash so I can´t try the  
[AS]message\_txt.text = "You picked  
Size “+size+”  
Quantity "+quantity;[/AS]  
code but if it ok with you what does the nSizw and nQUantity do I´ve never used them before.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 5, 2003, 8:28am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097/4 "2003-05-05T08:28:19Z")

</div>

represents a new line.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 5, 2003, 8:56am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097/5 "2003-05-05T08:56:40Z")

</div>

Ok did not now that!

That will help 🙂

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 5, 2003, 9:04am UTC](https://forum.kirupa.com/t/problems-with-textstring-from-combobox/20097/6 "2003-05-05T09:04:25Z")

</div>

😉 =)
