Hide group expand/collapse icons

2 posts, 0 answers
  1. Paul
    Paul avatar
    3 posts
    Member since:
    Mar 2012

    Posted 06 Jun 2012 Link to this post

    Hi,

    Is there anyway I can hide the expand/collapse icons based on a value calculated in the GridGroupByExpression?

    For example I want to hide the icon if the the GroupByField 'Count' aggregate = 0:

    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" LoadingPanelID="RadAjaxLoadingPanel1">
                <telerik:RadGrid ID="rdgSurveys" runat="server" AllowPaging="false" Skin="Office2010Silver"
                    OnNeedDataSource="rdgSurveys_NeedDataSource" OnItemDataBound="rdgSurveys_ItemDataBound"
                    OnItemCreated="rdgSurveys_ItemCreated">
                    <MasterTableView AutoGenerateColumns="False" HeaderStyle-HorizontalAlign="Center" HierarchyDefaultExpanded="false">
                        <GroupByExpressions>
                            <telerik:GridGroupByExpression>
                                <SelectFields>
                                    <telerik:GridGroupByField FieldName="Ref" FieldAlias="Survey" />
                                    <telerik:GridGroupByField FieldAlias="Count" FieldName="SumField" Aggregate="Sum" />
                                </SelectFields>
                                <GroupByFields>
                                    <telerik:GridGroupByField FieldName="Ref" SortOrder="Ascending"></telerik:GridGroupByField>
                                </GroupByFields>
                            </telerik:GridGroupByExpression>
                        </GroupByExpressions>
                        <Columns>
                            <telerik:GridBoundColumn DataField="DateCreated" DataType="System.DateTime" HeaderText="Date Created"
                                UniqueName="DateCreated" DataFormatString="{0:dd MMM yyy hh:mm}" />
                            <telerik:GridBoundColumn DataField="Version" DataType="System.String" HeaderText="Version"
                                UniqueName="Version" />
                            <telerik:GridBoundColumn DataField="Respondent" DataType="System.String" HeaderText="Completed By"
                                UniqueName="Respondent" />
                        </Columns>
                    </MasterTableView>
                </telerik:RadGrid>
            </telerik:RadAjaxPanel>

     
  2. Abhishek
    Abhishek avatar
    45 posts
    Member since:
    Jul 2012

    Posted 06 Jun 2012 Link to this post

  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top