Disclosure Triangle over Listbox

Hi all, good morning :stuck_out_tongue:

I’m working on create an Interface similar to a Excel Spreadsheet, The Fist part its solved.

  1. Get all the Values of the Listbox to an array: This is in order to not to make a SQL Query each time I need to want to make filter of each column on table.
    I probe it and is Faster as this way.Now I can I consult the columns in array in order to make menus like filters.

  2. The Next One is To create Disclosure Triangles: I draw an Disclosure Triangle over the header of column of my Listbox.
    The issue became when click over the header, the Disclosure triangle disappears. Is there a way to get Disclosure Triangle visible always on top?

Thanks.

For #2 are you looking to emulate the “FILTER” funciton of EXCEL?
If so, you will need to create a custom Listbox Header (search this forum, somewhere I posted a link to one I wrote a few years back, that you can use as a starting point)

[quote=209461:@Dave S]For #2 are you looking to emulate the “FILTER” funciton of EXCEL?
If so, you will need to create a custom Listbox Header (search this forum, somewhere I posted a link to one I wrote a few years back, that you can use as a starting point)[/quote]
Yes Dave, I’trying to emulate the “FILTER” function of Excel.
I’m gonna search that post. Thanks in advance

this package is for OSX only (the code should work for OSX/WIN, but I stored it as a DMG not a zip back in 2012 :slight_smile: )

www.rdS.com/listbox_header.dmg

[quote=209468:@Dave S]this package is for OSX only (the code should work for OSX/WIN, but I stored it as a DMG not a zip back in 2012 :slight_smile: )

www.rdS.com/listbox_header.dmg[/quote]
Thanks so much Dave!!, you’re great :smiley: :smiley:

I’m Working on the Custom Listbox Header. I draw Triangles at one side of each label at the left side on the Paint event.

I wonder if theres a way to get coordinates of where I’m clicking. Like mapping an image. Or I dunno If my idea is correct. Or what do you suggest?

I guess you didn’t download my control… you have access to all that data…

Ok I Got it, the listbox header already have Event handlers
I thought that what Am I looking for is the ConstructContextualMenu event handler of the ListboxHeader