如何从Telerik RadGrid向上移动第一行

时间:2019-02-19 09:32:38

标签: c# asp.net radgrid

我做了一个telerikRadGrid并以编程方式更改为开始可分组。但是,现在我需要在他折叠时显示折叠行中每个类别的第一行,并且当我扩展内容时,该行将从第一行开始下降。我可以这样做吗?

我曾经尝试在Internet上找到某些内容,甚至在RadGrid官方网站中也没有找到任何内容。

<telerik:RadGrid ID="gvStatus" runat="server" Skin="Bootstrap" CssClass="GridDesign" AllowPaging="True" OnNeedDataSource="GvStatus_OnNeedDataSource"
                AllowAutomaticUpdates="True" AllowAutomaticDeletes="True" AllowAutomaticInserts="True" AllowFilteringByColumn="True"
                AllowSorting="True" AutoGenerateColumns="False" ShowGroupPanel="True"
                EnableHeaderContextFilterMenu="True" EnableHeaderContextMenu="True" AutoGenerateHierarchy="True" EnableGroupsExpandAll="True" MasterTableView-AllowCustomSorting="True">
                <PagerStyle Mode="NextPrevAndNumeric" />
                <GroupingSettings CaseSensitive="False" ShowUnGroupButton="True" RetainGroupFootersVisibility="True" />
                <ExportSettings FileName="Roles" IgnorePaging="True" OpenInNewWindow="True">
                    <Csv ColumnDelimiter="Semicolon" />
                </ExportSettings>
                <ClientSettings AllowColumnsReorder="True" AllowDragToGroup="True" ReorderColumnsOnClient="True">
                    <Selecting AllowRowSelect="True" />
                    <Scrolling AllowScroll="False" UseStaticHeaders="False" />
                    <ClientEvents></ClientEvents>
                </ClientSettings>
                <MasterTableView DataKeyNames="Product" ClientDataKeyNames="Product" CommandItemDisplay="Top" PageSize="10"
                    Width="100%" BackColor="white" HierarchyDefaultExpanded="False" EnableGroupsExpandAll="True" HierarchyLoadMode="ServerBind" GroupsDefaultExpanded="False">
                    <GroupByExpressions>
                        <telerik:GridGroupByExpression>
                            <GroupByFields>
                                <telerik:GridGroupByField FieldName="Product" />
                            </GroupByFields>
                            <SelectFields>
                                <telerik:GridGroupByField FieldName="Product" />
                            </SelectFields>
                        </telerik:GridGroupByExpression>
                    </GroupByExpressions>
                    <CommandItemSettings ShowExportToWordButton="true" ShowExportToExcelButton="true"
                        ShowExportToCsvButton="true" ShowExportToPdfButton="true"></CommandItemSettings>
                    <RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column">
                    </RowIndicatorColumn>
                    <ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column">
                    </ExpandCollapseColumn>
                    <Columns>
                        <telerik:GridBoundColumn DataField="Product" HeaderText="Product" UniqueName="Product"
                            SortExpression="Product" Groupable="True">
                            <HeaderStyle ForeColor="#333333" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Customer" HeaderText="Customer" UniqueName="Customer"
                            SortExpression="Customer" Groupable="True">
                            <HeaderStyle ForeColor="#333333" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Agent" HeaderText="Agent" UniqueName="Agent"
                            SortExpression="Agent" Groupable="True">
                            <HeaderStyle ForeColor="#333333" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataType="System.DateTime" DataField="PlacementDate" HeaderText="PlacementDate" UniqueName="PlacementDate" DataFormatString="{0:dd/MM/yyyy}">
                            <HeaderStyle HorizontalAlign="Center" ForeColor="#333333" Width="150px" />
                            <ItemStyle HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Status" HeaderText="Status" UniqueName="Status"
                            SortExpression="Status" Groupable="True">
                            <HeaderStyle ForeColor="#333333" HorizontalAlign="Center" />
                        </telerik:GridBoundColumn>
                    </Columns>
                </MasterTableView>
                <FilterMenu EnableImageSprites="False">
                </FilterMenu>
            </telerik:RadGrid>

我希望桌子收起来时爬上第一行

0 个答案:

没有答案