Ok I have some very odd behavior with a radgrid. I am trying to set it up so that it will filter the columns when the enter key is hit. I have set up the gid and it never seems to acknowledge the enter key being pressed, but it will work when I hit the tab key. I can live with this if necessary, but the odd thing is this.
When the page loads I can filter the column, case sensitive, on whatever column I have set up with AutoPostBackOnFilter = true. The issue is when I go to another column and try to filter it. If it is not set to AutoPostBackOnFilter and use the GUI drop down it works. But if I try and filter on another column with AutoPostBackOnFilter set to true the grid does not filter and blanks out the filter box when I tab off it.
More odd behavior I can keep filter on whatever column I first filtered on with no issue, except when I do certain things, like try to filter on another column with the Autopost back set and then remove filter on a column without autopostback and then try to filter with my original column. Then it does the same thing blanks the filter box and does not filter.
It always filters if I do not use autopostback. Here is some of the code.
| <telerik:RadGrid ID="RadGrid1" runat="server" AllowSorting="True" |
| GridLines="None" |
| Skin="WebBlue" AllowFilteringByColumn="True" |
| AutoGenerateColumns="False" |
| EnableTheming="False" onneeddatasource="RadGrid1_NeedDataSource" |
| ShowGroupPanel="True"> |
| <HeaderContextMenu EnableTheming="True"> |
| <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> |
| </HeaderContextMenu> |
| <MasterTableView DataKeyNames="ClientID"> |
| <RowIndicatorColumn> |
| <HeaderStyle Width="20px"></HeaderStyle> |
| </RowIndicatorColumn> |
| <ExpandCollapseColumn> |
| <HeaderStyle Width="20px"></HeaderStyle> |
| </ExpandCollapseColumn> |
| <Columns> |
| <telerik:GridBoundColumn DataField="ClientID" DataType="System.Int32" |
| HeaderText="ClientID" ReadOnly="True" SortExpression="ClientID" |
| UniqueName="ClientID" Visible="false"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="LastName" HeaderText="Last Name" |
| SortExpression="LastName" UniqueName="LastName" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" > |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="FirstName" HeaderText="First Name" AutoPostBackOnFilter="true" CurrentFilterFunction="Contains" |
| SortExpression="FirstName" UniqueName="FirstName"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="RecordAccountName" HeaderText="Account Name" |
| SortExpression="RecordAccountName" UniqueName="RecordAccountName"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="StrategyTypeDescription" |
| HeaderText="Strategy" SortExpression="StrategyTypeDescription" |
| UniqueName="StrategyTypeDescription" Groupable="true" GroupByExpression="StrategyTypeDescription, Sum(InitialInvestmentAmount) GroupTotal [Group Total] Group By StrategyTypeDescription"> |
| </telerik:GridBoundColumn> |
| <telerik:GridBoundColumn DataField="IntermediaryDescription" |
| HeaderText="Intermediary" SortExpression="IntermediaryDescription" |
| UniqueName="IntermediaryDescription"> |
| </telerik:GridBoundColumn> |
| protected void RadGrid1_NeedDataSource(object source, Telerik.Web.UI.GridNeedDataSourceEventArgs e) |
| { |
| RadGrid1.DataSource = ClientBLL.GetClientsNotInvested(); |
| } |
| public static List<APAPortal.vw_clients_pending> GetClientsNotInvested() |
| { |
| APADataContext db = new APADataContext(); |
| var query = from c in db.vw_clients_pendings |
| select c; |
| return query.ToList(); |
| } |
Sorry just discoverd that it is using controls version 2008.3.1314. This might be the issue