I split the window and the left panel is a treectrl. I hope the right
panel is generated according to the item value selected by
EVT_TREE_SEL_CHANGED. So I wrote a LoadRightPanel() whose main
content includes:
Actually I want to generate the right panel depending on the item-
related data (labels, radios, text input, etc).
Maybe wxListBook is a better choice, but I still prefer the TreeCtrl
looking and also I'm wondering why the function I wrote cannot work.
Any further suggestion?
···
On 4月20日, 下午1时11分, C M <cmpyt...@gmail.com> wrote:
On Tue, Apr 19, 2011 at 10:32 PM, Gagiel <gagi...@gmail.com> wrote:
> Hi everyone,
> I split the window and the left panel is a treectrl. I hope the right
> panel is generated according to the item value selected by
> EVT_TREE_SEL_CHANGED. So I wrote a LoadRightPanel() whose main
> content includes:
two places in your code, you will get the error you see. Because you are trying to add the same window (the LabelTitle) to the sizer twice.
Actually I want to generate the right panel depending on the item-
related data (labels, radios, text input, etc).
Maybe wxListBook is a better choice, but I still prefer the TreeCtrl
Then just use Treebook. Have you looked at Treebook? It does exactly what you are wanting (as I understand you). See the demo.
looking and also I’m wondering why the function I wrote cannot work.
Without seeing all the code, who knows for sure (though I think it’s because of what I wrote above). If you write a small runnable sample, people can help you.