# Populating a combo box in mx 04

**URL:** <https://forum.kirupa.com/t/populating-a-combo-box-in-mx-04/223979>\
**Category:** Uncategorized\
**Created:** [April 27, 2007, 8:28am UTC](https://forum.kirupa.com/t/populating-a-combo-box-in-mx-04/223979 "2007-04-27T08:28:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![twistedpixel](https://avatars.discourse-cdn.com/v4/letter/t/35a633/32.png) [@twistedpixel](https://forum.kirupa.com/u/twistedpixel)\
**Post date:** [April 27, 2007, 8:28am UTC](https://forum.kirupa.com/t/populating-a-combo-box-in-mx-04/223979/1 "2007-04-27T08:28:50Z")

</div>

Hi,  
I want to populate the options that appear in a combo component from an external text file. How to go about doing it ?..

The txt for the file is…

[“Option 1”,“Option 2”,“Option 3”,“Option 4”,“Option 5”]

This has to come inside the combo…i tried to give it like this…

```auto

combo.addItem(loadVariablesNum("mydata.txt",0));

```

which didn’t work. Should i have a function where i strip out the commas, quotes etc ? an then assign them ?..please advise…
