Print Page | Close Window

[Ask] Print Last Record

Printed From: Crystal Reports Book
Category: Crystal Reports for Visual Studio 2005 and Newer
Forum Name: Writing Code
Forum Discription: .NET programming API, report integration
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=19645
Printed Date: 28 Mar 2024 at 2:56pm


Topic: [Ask] Print Last Record
Posted By: Herfian
Subject: [Ask] Print Last Record
Date Posted: 12 Jun 2013 at 6:48pm
Dear All,

I want print last record using index record and using Group Selection Formula Editor, example like this :

{"099/MM/2013"}=Maximum ({"099/MM/2013"})

And my problem is : if that record get a reset number fieldindex on next year, a report still preview a maximum summary number. how to solution my case.

Thanks



Replies:
Posted By: hilfy
Date Posted: 14 Jun 2013 at 8:16am
Something is lost in translation here, so let me see whether I understand your question.
 
You want to show just the last record for each group for the current year.  Is that correct?
 
If so, you don't need the Group Selection Editor.  Instead, I would do something like this:
 
1.  In the Record Select Expert, edit the selection formula and add something like the following to it:
 
{MyTable.MyDateField} <= Date(Year(CurrentDate), 12, 31)
 
This will give you only the data for this year.
 
2.  In the report, suppress the details section.  Put your data in the Group Footer section.
 
3.  If you need the data in the Group Header, set the group to sort Descending and use the Group Header section instead of the footer.
 
-Dell


-------------
Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics



Print Page | Close Window