# List component sortItemsBy problem

**URL:** <https://forum.kirupa.com/t/list-component-sortitemsby-problem/289161>\
**Category:** Uncategorized\
**Created:** [May 27, 2009, 2:20am UTC](https://forum.kirupa.com/t/list-component-sortitemsby-problem/289161 "2009-05-27T02:20:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lordali](https://avatars.discourse-cdn.com/v4/letter/l/59ef9b/32.png) [@lordali](https://forum.kirupa.com/u/lordali)\
**Post date:** [May 27, 2009, 2:20am UTC](https://forum.kirupa.com/t/list-component-sortitemsby-problem/289161/1 "2009-05-27T02:20:05Z")

</div>

I have looked everywhere but couldn’t find any solution to this.

Using CS4, AS3  
List component and the code is

MyList.sortItemsBy({“label”, “ASC”});  
tried  
MyList.sortItemsBy(“label”, “ASC”);

Generating error below  
1061: Call to a possibly undefined method sortItemsBy through a reference with static type fl.controls:List.

Can someone tell what am I doing wrong?
