Click here to Skip to main content
15,880,608 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I already have a table in place where I have set the autogeneratedcolumns to false and allowsorting to true. Furthermore, I have an event created onsorting, now when I run, the header links are not clickable like the ones you have when autogeneratedcolumns is set to true. Hence the event onsorting is not getting triggered.

What I have tried:

C#
AllowPaging="True"
                   PageSize="20"
                   CssClass="mGrid"
                   AllowSorting="True"
                   OnSorting="propertySearchDataGrid_Sorting"
                   PagerStyle-CssClass="pgr"
                   AlternatingRowStyle-CssClass="alt"
                    AutoGenerateColumns="False"


My settings are as above.
Posted
Updated 20-Apr-18 6:28am

1 solution

I got the solution, I forgot to put the "
SortExpression
" in my code.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900