Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
How to changes Dynamically the colour, font, etc of dyanmically created tables columns on demand
BIRT_SRS
Hi Guru,
I had created the dynamic coloumn by writing some script in BeforeFactory and also with help of CSS I had assigned the required font, colour, size, etc to Header, Group Header, Detail, Group Footer, Footer, etc. Which is working fine.
My problem is that If I use CSS the font, color, etc is appliacable to entier section.
But, I want to set the colour, font, size. etc to 3rd or 5th coloumn .... or it can be any coloum as per client demmand which is always changning at Header column, same way Group Header column, Detail Column, Group footer column, footer column.
Secondly, if in the particular column the figure is suppose negative I want to change the color, background, font, etc of that cell only.
It will be great thank If any body can help me to develope such type of script/code for fulfill the above requirments.
Thank in advance
Shantanu
Find more posts tagged with
Comments
JasonW
Take a look at the attached examples.
Jason
BIRT_SRS
Dear Jason,
I am very thank full to you for your quick response. Let me go through the example. In case of any doubt or problem I will be back.
Thanks
Shantanu
BIRT_SRS
<blockquote class='ipsBlockquote' data-author="'JasonW'" data-cid="101427" data-time="1338310970" data-date="29 May 2012 - 10:02 AM"><p>
Take a look at the attached examples.<br />
<br />
Jason<br /></p></blockquote>
BIRT_SRS
Hello Dear Jason,
Lot of thanks for attachment. I am new in BIRT. By going through the example some what I have got idea.
But it will be great if you explore by creating one small report for me where I can assign following things
Font colour, Background Colour, Font Family, Font weight, Font size, Width and height of column, etc.
I had notice that when background color is assign to zer(0)row of Detail column the same background color
also getting assign to Header column.
I want to assign different color to Header column and different color to detail column. Same if I create Grouping then in that case also I want to assign different color Group header of particular column.
I had also gone one of the example ie. StylePropsBasedonDataValue.rptdesign where only particular cell is highlighted as green for specific type of value. But the scripted was "oncreate" mehtod of 3rd column ie. "QUANTITYORDERED" which is right.
But here I don't know which column I had to highlight and on which value. It will be on client demand.
For your information I had developed one small report where I had taken a one table with one column. Binded with the dataset. And then I just adding the column as per the client requirments.
I awaiting for your response.
Thanks
Shantanu
JasonW
Can you design a report off the sample database and let me know what you want to color? Then post the example. BTW you know you can create a style in the report and apply it to anything without scripting. You can also add highlights that are based on parameters or data values.
Jason
BIRT_SRS
Hello Jason,
PFA demand_column.rpt with Style2.css. FYI I had used the standard sample data of BIRT.
Also PFA of result in Result_1.xls and Result_1.gif as well.
The require Result please refer to Requ_Result_2.xls and Requ_Result_2.gif as well.
Also I want to create group dynamically on "ORDERNUMBER" and total on column "PRICEEACH" as well with different colour, font, etc.
Please I am expecting from you small report which cover my all the above/following requirements.
Awaiting for important response.
Thanks
Shantanu
BIRT_SRS
Hello Jason,
Awaiting for your Solution response.
Thanks
Shantanu
JasonW
Take a look at the attached modifed example.
Jason
BIRT_SRS
Hello Jason,
After runing the dynamic.rptdesign the output which I was expecting is very much near. Lot of Thanks
But there is few query That, Went we does not change the column "Product Code" Header part color as blue why it is changed automatically? and related group column colour also is changed.
I am attaching the result in xls(Current_Result.xls) which is generate from dynamic.rptdesign and the result which is required in Expect_Result_04.xls.
However, I would like to described the same thing here also so that you focus only on the changes require
1. The Report Column header "Quantity Order", "Product code" colour should not be the same(Please see
the Expect_Result_04.xls)
2. I had select the "Quantity Order" because it numeric and it will be very easy to describe.
The Report Column header "Quantity Order" should be Right Align with font type "Times New Roman" and font size 10. And in case of Detail column of "Quantity Order" it should be Right Align with 2 decimal format,
font type should be "sans-serif" and font size should be 8. (Please see the Expect_Result_04.xls)
3. I want to highlight for the value more then 100 in column "Price Each" (Plese see the Expect_Result_04.xls)
4. Plese put Group Total for column "Quantity Order" with different color, font, size, etc. (Plese see the Expect_Result_04.xls)
5. And at last Grand Total for column "Quantity Order" with different color, font, size, etc. (Plese see the Expect_Result_04.xls)
It will be great thanks if you response with solution quickly for all above queries.
Lots of thanks in advance.
Shantanu
BIRT_SRS
Hello Jason,
Awaiting for your important Solution response.
Thanks
Shantanu
JasonW
I did some of the items for you. You should be able to complete the rest with this example.
Jason
BIRT_SRS
Hello Jason,
Lot of many thanks for providing the solution to me. At present you are really guru for me. Please keep in touch. Thanks once again.
Thanks
Shantanu