Good morning,
strange problem using filter with FMXGrid under android.
In a form i have the grid (filled, sorted) and 3 radio buttons.
The grid has last column (n.11) setted with "Flag" and the flag can be 1 or 2.
Here the code of all 3 radio buttons
procedure FMX_Form1.RB1Change(Sender: TObject);
begin
SG1.RemoveFilter;
SG1.Filter.Clear;
end;
procedure FMX_Form1.RB2Click(Sender: TObject);
begin
SG1.RemoveFilter;
SG1.Filter.Clear;
with SG1.Filter.Add do
begin
Column:=11;
Condition:='= 1';
end;
SG1.ApplyFilter;
end;
procedure FMX_Form1.RB3Click(Sender: TObject);
begin
SG1.RemoveFilter;
SG1.Filter.Clear;
with SG1.Filter.Add do
begin
Column:=11;
Condition:='= 2';
end;
SG1.ApplyFilter;
end;
RB1 = Radiobutton1 (ecc..)
What is happend is that if i "click" over RB2 (or RB3) nothing happend ....
The filter is not, apparently, applied, so i tap one of the other radio buttons and the filter works.
If i tap the rb2 or rb3 the filter works well, i have the grid filtered for "flag 1 o 2" but if i tab on rb1, i reset the filter (remove all filter) the grid will be without filter (i see all record, good) and if i try to set the filter again .... i'm in the starting position (the filter works only to second tap).
Can you tell me where i make a mistake ??
Thank's
Daniele