I use LookupItems in my AdvStringGrids, which work quite well.
But now I/my customers want to have that only for certain colums.
1. is it possible to use/avoid LookupItems in certain colums ?
2. is it possible to use different LookupItems for different colums ?
Thanks/Regards, Tom
I guess there is no simple solution such as a property or event to hook in for that.
Should I place a feature request for that to see if there is interest beside of mine ??
Regards, Tom
I found a solution to use/avoid LookupItems in certain columns only,
I simply set AdvStringGrid.Lookup := True/False in ColChanging-event depending on the NewCol...
The recommended place to customize the LookupItems behavior would be from the grid.OnGetEditorProp event.
Add some code in there like:
procedure TForm1.AdvStringGrid1GetEditorProp(Sender: TObject; ACol,
ARow: Integer; AEditLink: TEditLink);
begin
case acol of
1,3,5: Advstringgrid1.LookupItems.Assign(firstlist);
2,4,5: Advstringgrid1.LookupItems.Assign(secondlist);
end;
end;