Hi there,
How do i know wchich item is selected in TAdvPolyList ?
Cheers
Yeah, i tried this, but :
AdvPolyList1->SelectItem(0);
ShowMessage(AdvPolyList1->List->SelectedItem()->Index);
Gives me access violation (C++ Builder XE6 Pro) :(
also in POlylist overwiew demo2 (Delphi XE2 Starter):
AdvVerticalPolyList3.SelectItem(0);
ShowMessage(IntToStr(AdvVerticalPolyList3.List.SelectedItem.Index));
Or if i click on item and try to get selected index...
---------------------------
Debugger Exception Notification
---------------------------
Project FairWare.exe raised exception class $C0000005 with message 'access violation at 0x00536d76: read of address 0x00000008'.
---------------------------
Cheers
Of course delphi Tokyo 10.2 Starter
You always need to check if the SelectedItem is assigned to avoid an access violation. But do you really have selectable items?