Author Topic: tree control  (Read 596 times)

Moshe-A

  • Member
  • *
  • Posts: 16
tree control
« on: January 18, 2021, 06:44:07 AM »
hi,

Double click on a collapsed item expand it (if it has child items of course) and re-double click on the same item collapse it - that's understood.
if i define the DblClicked event (let call it 'MyCustom') now there are 2 events. who is fires first and who last? cause from what i see
'MyCustom' is first cause if i want to leave the item (and his childs) expanded (with a call to ExpandItem) it endup collapsed - is there a workaround?

and about GetItemData \ SetItemData it get\ set a Long data. is it possible to store strings, lists?
(or i have to manage that on my own data list?)

thanks
Moshe

owenwengerd

  • Administrator
  • Hero Member
  • *****
  • Posts: 3048
    • Outside The Box
Re: tree control
« Reply #1 on: January 21, 2021, 08:00:47 PM »
I believe the DblClicked event is a pure notification that happens after the double click is already handled by the control. I don't see any way to block it, unfortunately. For item data, you would need to manage the strings in your code by mapping to long integer and using the integer value as item data.

Moshe-A

  • Member
  • *
  • Posts: 16
Re: tree control
« Reply #2 on: January 23, 2021, 01:41:12 AM »
Owen hi,

thanks, i thought it would be that.

Moshe