Hi All
I am using a crosstab for generating a report. Now there is a new requirement, based on the users input there are some columns to be hide. I did follow some approaches and end up with the same problem.
1. Use bindings for the column and set visible false. Resulting column not visible but still white space is still there. (this happens only for grouped columns)
2. Set width to be 0 for the column index. Columns are hidden but space for the header still there and last column header of the grouping is missing
Is there a way to hide any column including header of the crosstab according to the index of the column from left.
following is the code i used for set width of columns
I am using a crosstab for generating a report. Now there is a new requirement, based on the users input there are some columns to be hide. I did follow some approaches and end up with the same problem.
1. Use bindings for the column and set visible false. Resulting column not visible but still white space is still there. (this happens only for grouped columns)
2. Set width to be 0 for the column index. Columns are hidden but space for the header still there and last column header of the grouping is missing
Is there a way to hide any column including header of the crosstab according to the index of the column from left.
following is the code i used for set width of columns
int count = 0;
var rowGroups = this.crosstab1.RowGroups;
while (rowGroups != null)
{
foreach (var group in rowGroups)
{
if (hideColumnIndexes.Contains(count))
{
group.ReportItem.Width = new Telerik.Reporting.Drawing.Unit(0.000000,
Telerik.Reporting.Drawing.UnitType.Inch);
}
}
if (rowGroups.Any())
{
rowGroups = rowGroups[0].ChildGroups;
}
else
{
rowGroups = null;
}
count++;
}