The forum for ZeosLib 7.2 Report problems. Ask for help, post proposals for the new version and Zeoslib 7.2 features here. This is a forum that will be edited once the 7.2.x version goes into RC/stable!!
My personal intention for 7.2 is to speed up the internals as optimal a possible for all IDE's. Hope you can help?! Have fun with testing 7.2
procedure TNGrid.EditChange(Sender: TObject);
Var
En_tete : string; //header name
begin
if (Col <> Null) and (Col >= CFix) then
En_tete := MyDataset.Fields[Col-1].DisplayName;
if NOT (TEdit(Sender).Text = '') then
begin
MyDataset.Filtered:= false;
MyDataset.Filter:= En_tete+' like ''*'+TEdit(Sender).Text+'*''';
MyDataset.Filtered:= true;
end
else
begin
MyDataset.Filtered:= false;
MyDataset.Filter:='';
end;
Filter2();
end;
I can't filter the last character .
And when the cell contains one char then it does not filter at all.
thanks for your help.
Filtering works just fine from 0 characters up. What I can see is that you are NOT ignoring the case, which means the value "Test" will not show up if you filter "like '%S%'".
the result of ShowMessage(MyDataset.Filter); is : NOM like LOWER('*a*') // NOM is the header of the Column.
All records with an 'a' will show unless it ends with an 'a' or the cell squals an 'a' then it doesn't filter.
it's like as if it doesn't read the last char at all (IsMatch or the LIKE Operator).