Solved

On Get Footer Summary Styles Event assistance

Posted on 2013-02-04
9
405 Views
Last Modified: 2013-06-07
I need to highlight the group summary box based on its value being over $350,000.  My code only gives me NULL values.  Help? (i also included commented code that continues to give me NULL AValues)

//  AIndex :=  AView.DataController.Summary.FooterSummaryItems.IndexOfItemLink(gvSalesForecastSales_Amount);
//  AValue := AView.DataController.Summary.FooterSummaryValues[AIndex];
//
//  if ((AColumn = gvSalesForecastSales_Amount) and (AFooterGroupLevel <> -1) and (AValue > 350000)) then AStyle := dmLeads.cxStyle2;

  if (AColumn.Index = 6) and (AView.DataController.Summary.FooterSummaryValues[AColumn.Index] > 350000) then
   AStyle := dmLeads.cxStyle2;

Open in new window

0
Comment
Question by:Bianca
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 2
9 Comments
 
LVL 19

Expert Comment

by:Thommy
ID: 38853212
This should work...
AIndex :=  AView.DataController.Summary.FooterSummaryItems.IndexOfItemLink(gvSalesForecastSales_Amount);
AValue := AView.DataController.Summary.FooterSummaryValues[AIndex];

if (AValue > 350000) then AStyle := dmLeads.cxStyle2;

Open in new window

0
 

Author Comment

by:Bianca
ID: 38853219
I tried that and it looks like it keeps giving me the same Index and NULL Value. Trying it again...
0
 

Author Comment

by:Bianca
ID: 38853232
It highlighted all Group Summary items even though they were not more than 350000. Am I using the wrong event?  The summary that I am using values on is the Group Footer Summary Values (not the footer)
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Bianca
ID: 38853240
Let me clarify that. I have a subgrouping by date. If the subgrouped values for SalesAmount within that group (that group's summary value) is over $350,000 then highlight that Group Footer Summary Value.
0
 
LVL 19

Accepted Solution

by:
Thommy earned 500 total points
ID: 38854059
The right events are OnGetGroupSummaryStyle or OnCustomDrawGroupSummaryCell ...

This will probably help you...
Group summary color based on group by index

Also have a look at the downloadable sample code at the above url...
0
 

Author Comment

by:Bianca
ID: 38855388
I need to apply styles based on values not row index.

How do I get the value of the group footer summary?
0
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 38858326
are you precreating the footers or letting the users create the footers and then highlight them  ?
0
 

Author Comment

by:Bianca
ID: 38859579
I set the group footer summary on the grid myself.. Those are the values I want to highlight based on if they are greater than $350000
0
 

Author Comment

by:Bianca
ID: 38859693
Here's a screenshot; I want those highlights there but ONLY if that group summary total is over $350000
untitled.bmp
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question