This is a migrated thread and some comments may be shown as answers.

Grid Grouping Item Format/Layout Advice

4 Answers 80 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Stuart
Top achievements
Rank 1
Stuart asked on 26 Jul 2012, 02:16 PM
Hi All

I am creating a new grid and using the RadGrid grouping facilities. My Grid is displaying what i need but i would like some advice on how to format the GroupHeader, I was able to set font etc but I would like to have equal spacing between the Titles etc.. I have attached the grid to show what it currently looks like. 

Thanks

4 Answers, 1 is accepted

Sort by
0
Jayesh Goyani
Top achievements
Rank 2
answered on 26 Jul 2012, 07:50 PM
0
Stuart
Top achievements
Rank 1
answered on 27 Jul 2012, 10:01 AM
Thanks that was helpful. I have another grouping issue on a similar table.

Working on a similar grid with two levels of grouping, I have an issue with the second level GroupHeader element when I have a select field sum aggregate.  For every first row on the second grouping does not show the sum aggregate just {0}, all other rows show as expected. N.B When select field for second expression has not aggregate it groups as expected.

The attached file shows I would expect  first row on "Toyota" to be [Location]Toyota; NumberOfEnquiries3 (N.B, [Location] is blanked out on row below), Row 2 is correct. This is replicated on all first rows of second grouping. Any advice greatly appreciated.

<telerik:GridGroupByExpression>
                           <SelectFields>
                               <telerik:GridGroupByField FieldAlias="Franchise" FieldName="RootLevel" FormatString=""
                                   HeaderText=" " />
                               <telerik:GridGroupByField Aggregate="Sum" FieldAlias="NumberOfEnquiries" FieldName="NumberOfEnquiries"
                                   FormatString="" HeaderText=" " />
                               <telerik:GridGroupByField Aggregate="Sum" FieldAlias="NumberOfQuotes" FieldName="NumberOfQuotes"
                                   FormatString="" HeaderText=" " />
                               <telerik:GridGroupByField Aggregate="Sum" FieldAlias="NumberOfOrders" FieldName="NumberOfOrders"
                                   FormatString="" HeaderText=" " />
                           </SelectFields>
                           <GroupByFields>
                               <telerik:GridGroupByField FieldAlias="RootLevel" FieldName="RootLevel" FormatString=""
                                   HeaderText=" " SortOrder="None" />
                           </GroupByFields>
                       </telerik:GridGroupByExpression>
                       <telerik:GridGroupByExpression>
                           <SelectFields>
                               <telerik:GridGroupByField FieldAlias="Branch" FieldName="SubLevel1" FormatString=""
                                   HeaderText=" " />
                               <telerik:GridGroupByField Aggregate="Sum" FieldName="NumberOfEnquiries" FieldAlias="NumberOfEnquiries"
                                   HeaderValueSeparator="" HeaderText="" />
                           </SelectFields>
                           <GroupByFields>
                               <telerik:GridGroupByField FieldAlias="SubLevel1" FieldName="SubLevel1" FormatString=""
                                   HeaderText="" />
                           </GroupByFields>
                       </telerik:GridGroupByExpression>
                   </GroupByExpressions>



0
Accepted
Tsvetina
Telerik team
answered on 01 Aug 2012, 08:04 AM
Hi Stuart,

Have you tried removing the empty FormatString settings? Are they set this way for a reason?

Greetings,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Stuart
Top achievements
Rank 1
answered on 01 Aug 2012, 08:12 AM
Hi

I changed the FormatStrings to FormatString= {0} and this has solved the totals issue in the header. For formatting the GroupHeaders I used the Pre Render method of the grid to mathc the layout of the columns.

Thanks
Stuart
Tags
Grid
Asked by
Stuart
Top achievements
Rank 1
Answers by
Jayesh Goyani
Top achievements
Rank 2
Stuart
Top achievements
Rank 1
Tsvetina
Telerik team
Share this question
or