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

Telerik Report - Merge Cell & Conditional Formatting Issue

1 Answer 179 Views
Report Designer (standalone)
This is a migrated thread and some comments may be shown as answers.
Syed
Top achievements
Rank 1
Syed asked on 13 Apr 2018, 09:29 AM

Hello,

 

Currently, we are building  a telerik report, using Cell merge and conditional formatting functionality.

 

As per the attached screen, we have 3 different checkbox on the top of the screen and based on that we are displaying 3 different columns for each day (Image 1).

User can uncheck any of the checkbox and respective columns should be removed from the report and other columns should be working responsively and take remaining space and divide the space into 2(Image 2). Here, second column is not properly being set based on the total width(Here the first checkbox is unchecked).

 

If user is unchecking the last checkbox, the columns width are not being set and the space is still being occupied for 3rd-last column(Image 3) due to merge cell feature.

 

To achieve the same, we are hiding and showing the columns based on conditional formatting.

 

Urgent help would be highly appreciated.

 

 

 

 

 

 

1 Answer, 1 is accepted

Sort by
0
Todor
Telerik team
answered on 16 Apr 2018, 02:06 PM
Hi Syed,

I have noticed that you have opened a Support Ticket (#1162428) with the same content as this forum post. I have suggested a solution of the problem there.
For the benefit of the rest of the community members I will post the essence of my response and attach the sample also here.

If further questions on this topic arise I suggest to continue our discussion in the support ticket.

Following is my response to the support ticket:


My suggestion is to use a multivalue Report Parameter indicating which CheckBoxes are checked, and based on this parameter values to use Bindings to set the Visibility and Width of the columns.

The Column should be Visible if the corresponding CheckBox is checked, i.e. if its representative value/name is in the report parameter values. I suggest an Expression like:
= 'CheckBoxNameInParameter' In Parameters.ParameterName.Value

The Columns Width should be equal to the default one when all columns are Visible (for example W, in inches) multiplied by the total number of columns and divided by the number of visible columns, i.e.
=CStr(W*CDbl(TotalNumberOfColumns)/Parameters.ParameterName.Value.Length) + 'in'
Explicit conversion to Double is required since both the numerator and the denominator are Integer. The value of Width property is set as a string containing the width and the measuring unit.

I have attached a sample report demonstrating the approach.
In the sample W=1in (hence is omitted), TotalNumberOfColumns=6, and the AvailableValues (i.e. the possible CheckBoxNameInParameter) of the Multivalue Parameter (ParameterName is 'Hide') are 'id', 'value01' ... 'value05'.
By default all columns are Visible.

Regards,
Todor
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Report Designer (standalone)
Asked by
Syed
Top achievements
Rank 1
Answers by
Todor
Telerik team
Share this question
or