如何根据条件更改行的背景颜色 [英] How to change background color of row based on condition

查看:113
本文介绍了如何根据条件更改行的背景颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想改变基于矩阵的日期条件行的背景颜色,即每个星期日行。

实际上每个都有一个日期,我发现那个日期的日子如果它是星期日的背景颜色应该绿色。



我的代码在matrixrow4

I want to change background color of row of matrix based date condition i.e. every sunday row.
Actually every has a date, I found day of that date if it is sunday background color of row should be green.

My code is on matrixrow4

<pre lang="vb">
=Iif(WeekdayName(Weekday(FORMAT(Day(Fields!DATE.Value).ToString()+"/"+Month(Fields!DATE.Value).ToString()+"/"+Year(Fields!DATE.Value).ToString())))="Sunday", "#FFFF00","")



它适用于04/08/2013, 2013年8月1日至2013年10月10日期间11/08 / 2013,01 / 09/2013和08/09/2013

它没有改变完整的行背景颜色。


It is working for 04/08/2013 , 11/08/2013,01/09/2013 and 08/09/2013 in ranging 01/08/2013 to 10/09/2013
It is not changing complete row background color.

推荐答案

要填充整行的颜色,我认为您必须填写该行的每个文本框。

在文本框属性中,您将获得填充颜色属性,其中可以根据表达式填充颜色。

你必须根据你的逻辑来表达。您必须同样申请该行的每个文本框。根据您的表达式,将应用行颜色。
To fill color in entire row, I think you will have to fill each text box of that row.
In text box property, you will get fill color property where one can fill color based on the expression.
You will have to make expression according to your logic. The same you will have to apply for each text box of the row. Based on your expression, row color will be applied.


这篇关于如何根据条件更改行的背景颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆