Jump to content

Recommended Posts

Hello guys!


I have a UniDBGrid with some columns with the "Sortable" property enabled and the "OnColumnSort" event scheduled. Basically, I enter the field in the "IndexFieldName" property of TADQuery.

However, I need to clear this order ... Return to the original sort order, which is in the SQL query. Even closing and opening the query and clearing the property "IndexFieldName", prevails the ordering of the column that was clicked.


How to clear the ordering of the UniDBGrid columns?


Sorry for English. I'm brazilian.


Thank you!

Link to post
Share on other sites

One possible solution maybe:

procedure TMainForm.UniButton1Click(Sender: TObject);
  UniDBGrid1.JSInterface.JSCall('store.sorters.clear', []);
  //UniDBGrid1.JSInterface.JSCall('view.refresh', []);
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...