0

So I have a report that contains several orders. The report is grouped on Orders and the details are the items in an order:

    Order # 500
        Item #1
        Item #2
        Item #3
        Item #4

When an item meets a certain condition I want to highlight it. However I also want to highlight the group header, but only when the condition on the item is met. So if any of the items meet the condition the header should be highlighted. Highlighting the item is easy so that's not the issue. I'm having trouble highlighting the header.

I've tried setting a global variable when the item is highlighted but can't seems to get it to work.

Any help would be much appreciated!

4

1 回答 1

0

创建公式字段,添加到details部分,抑制:

// {@conditions}
// formula returns a 1 if any of the conditions are met
WhileReadingRecords; // force this to be evaluated will records are returning from DB
If {table.field}=[] Then
  1
// else if
// ...
Else
  0

将条件公式添加到页眉字段的背景颜色属性:

<strike>WhilePrintingRecords;  // force formula to evaluate during 3rd pass</strike>
If Sum({@conditions})>0 Then
  crSilver
Else
  crNoColor
于 2013-09-06T15:39:16.407 回答