Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Subreport: A summary has been specified in a non-recurring field

Status
Not open for further replies.

kuberacupidagra

Programmer
Oct 21, 2005
36
US
Hello All,

I get a parameter value called ReportYear1 of Type "Date" from the Main Report.

1)Have a formula in Main Report as:
@MyMain
whileprintingrecords;
shared numbervar reportyear := year({?ReportYear1})
This is placed in main report header

2)Have a formula in subreport as:
@ReportYear
whileprintingrecords;
shared numbervar reportyear;
reportyear;

When I place this formula in header of subreport I get a value of 2005.00 for Year 2005.

However, when I use this formula below it gives an error: A Summary has been specified on a non-recurring field.

d_start :=DateSerial({@ReportYear}, 12, 1)

Will appreciate your help to resolve this error.

Regards,

AA
 
The formula shouldn't work at all since you haven't declared the variable.

Try:

whileprintingrecords;
shared numbervar reportyear;
cdate(year(ReportYear}), 12, 1)

The dateserial is a good way to increment/decrement dates, but isn't required for your purposes.

-k
 
Thanks Synapsevampire,

I tried using the CDate function instead of DateSerial. The formula compiles fine but get the same run time error, "A Summary has been specified for a non recurring field".

Would appreciate feedback. I am using CR 10

Regards,

AA
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top