简体   繁体   中英

How to read from a text file and populate a combo box in flash AS3?

Suppose a text file contains the following data each separated by a line

Apple

Mango

Orange

Banana

Papaya

How do I read the text file in flash and then display it in a combo box in flash ?

使用URLLoader加载txt文件,然后获取String(data),解析它(string.split(“ \\ n”))并使用for()创建列表并添加到组合框。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM