Hi,
I'm wondering someone can help me with a ListBox problem. I'm trying to construct and display a ListBox in the container of my application. The ConstructL function looks like:
void CLbtestContainer::ConstructL(const TRect& aRect)
{
CreateWindowL();
iListBox = new (ELeave) CAknSingleStyleListBox;
iListBox->SetContainerWindowL(*this);
iListBox->ConstructL(this, EAknListBoxSelectionList);
array = new (ELeave) CDesCArrayFlat(5);
array->AppendL(_L("\tItem1"😉);
array->AppendL(_L("\tItem2"😉);
array->AppendL(_L("\tItem3"😉);
array->AppendL(_L("\tItem4"😉);
array->AppendL(_L("\tItem5"😉);
iListBox->Model()->SetItemTextArray(array);
iListBox->CreateScrollBarFrameL(ETrue);
iListBox->ScrollBarFrame()->SetScrollBarVisibilityL(CEikScrollBarFrame::EOff, CEikScrollBarFrame::EAuto);
SetRect(aRect);
ActivateL();
}
Everything compiles fine but when I run it in the emulator it instantly crashes. When I run it on my target device (3650) it immediately exits with a KERN-EXEC 3 panic. I've looked up the panic message but I'm still lost on what could be causing the problem. I would appreciate any feedback you can give. Thank you!
Regards,
Dennis