Tree item editing issue

This forum can be used to talk about general design strategies, new ideas and questions in general related to wxWidgets. If you feel your questions doesn't fit anywhere, put it here.
Post Reply
dzd
Earned a small fee
Earned a small fee
Posts: 14
Joined: Wed Apr 20, 2005 1:38 pm
Location: Aberdeen Scotland

Tree item editing issue

Post by dzd »

Hi !

I ve a problem when I catch the event EVT_TREE_END_LABEL_EDIT of my tree control.
I don't know how to get the new item text.

GetItemText(id) returns me the item text before editing, how to get the new ?

Thanks !
Avi
Super wx Problem Solver
Super wx Problem Solver
Posts: 398
Joined: Mon Aug 30, 2004 9:27 pm
Location: Tel-Aviv, Israel

Post by Avi »

In your event catcher function you recieve a wxTreeEvent object...
Take that object and call GetLabel:
wxTreeEvent::GetLabel

const wxString& GetLabel() const

Returns the label if the event was a begin or end edit label event.
:wink:
dzd
Earned a small fee
Earned a small fee
Posts: 14
Joined: Wed Apr 20, 2005 1:38 pm
Location: Aberdeen Scotland

Post by dzd »

Ok it works :)
Thanks a lot !
Post Reply