Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi there,
Anyone know how to change the test objects or table headers according to date?
thanks! in advance.
Go to Properties of Text Box
Select Color under Background section
Use Calculated under base color and write below expresssion
IF(WeekDay(Today()) = 'Mon', Green(),
IF(WeekDay(Today()) = 'Tue', Red(),
IF(WeekDay(Today()) = 'Wed', Blue(),
IF(WeekDay(Today()) = 'Thu', QlikTechGray(),
IF(WeekDay(Today()) = 'Fri', QlikTechBlue(),
IF(WeekDay(Today()) = 'Sat', RGB(100,100,100),
RGB(120,120,120)))))))
Can you please elaborate little more on your requirements?
for text colour you can goto tab expressions, click on your expressiom and click to plus
then yo ucan define Text color with if conditions
if date < today, rgb,128,128,128), rgb(255,255,255)
same for table header you can define depending ondate different texts (but not colour)
can you explain more abt requirement ? on change of date text color can be changed by using HRLinder
logic. but it is bit difficult to write logic for each date.
yeah of course I want something like
in a year 54 weeks so my Test Object's color have to change according to the weeks or days in a week
Eg:
Monday = blue
Tuesday = red
Thursday = green
else
Week1 = black
Week2 = yellow
Week3 = Pink
Go to Properties of Text Box
Select Color under Background section
Use Calculated under base color and write below expresssion
IF(WeekDay(Today()) = 'Mon', Green(),
IF(WeekDay(Today()) = 'Tue', Red(),
IF(WeekDay(Today()) = 'Wed', Blue(),
IF(WeekDay(Today()) = 'Thu', QlikTechGray(),
IF(WeekDay(Today()) = 'Fri', QlikTechBlue(),
IF(WeekDay(Today()) = 'Sat', RGB(100,100,100),
RGB(120,120,120)))))))
What I can suggest (i did it this way for one application with products where each product (about 12) should always have a defined colour) is, to nhance the datamodel (in my case I added a column "Productcol". I used if statements for each product. In my Text colour properties I could use this field "Productcol").
-> You need only one expression other than several if statements for each expression where you need these colours. In your case can you enhance a table with these colours (maybe the calendar or a new table attached to calendar)?
But if you have only one expression I would suggest like Manish description. If you have more than one, you migth consider my solution. Its always a question of maintain and work to do.