A AdvStringGrid1 has true properties Sortsettings.IndexShow, Sortsettings.Show.
After sorting Index Glyph at the Column header is shown.
And user reset that grid for initiation - like re-query.
For that, In codes, AdvStringGrid1.SortIndexes.Clear is called.
But the Index glyph was not cleared.
How to clear it?
Calling AdvStgringGrid1.repaint is not work.
Do
advstringgrid1.SortIndexes.Clear;
advstringgrid1.SortSettings.Show := false;
You mean
Procedure T1.btnQClick(Sender:TObject)
begin
advstringgrid1.clearNomalCells;
advstringgrid1.ClearRowSelect;
advstringgrid1.SortIndexes.Clear;
advstringgrid1.SortSettings.Show := false;
advstringgrid1.SortSettings.Show := True;
// ... Query and Set Data to grid
end;
If you need to sort again after this, yes.