# ListBox.SortColumn is not fired if the ListBox is empty!

**URL:** <https://forum.xojo.com/t/listbox-sortcolumn-is-not-fired-if-the-listbox-is-empty/74769>\
**Category:** General\
**Created:** [March 8, 2023, 9:41am UTC](https://forum.xojo.com/t/listbox-sortcolumn-is-not-fired-if-the-listbox-is-empty/74769 "2023-03-08T09:41:31Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![Rick\_Araujo](https://forum.xojo.com/user_avatar/forum.xojo.com/rick_araujo/32/251_2.png) [@Rick\_Araujo](https://forum.xojo.com/u/Rick_Araujo)\
**Post date:** [March 8, 2023, 8:53pm UTC](https://forum.xojo.com/t/listbox-sortcolumn-is-not-fired-if-the-listbox-is-empty/74769/10 "2023-03-08T20:53:14Z")

</div>

> [@Tim\_Hare](#):
>
> Clicking a listbox header (not buttton) affects the data currently in the listbox.

If you wish so. If you return true, it makes nothing to the column/sorting. And even if you do it so (return true at the end), you can change properties and take any actions while invoked. You could even set a property like currentColumnInFocus and set a different color for it. Many possibilities.

As said, the trigger happened (click), so the action MUST fire.

---

_[View the full topic](https://forum.xojo.com/t/listbox-sortcolumn-is-not-fired-if-the-listbox-is-empty/74769)._
