Avatar of Amour22015
Amour22015
 asked on

Crystal Reports 2008 - Too many arguments have been given to this function

Hi and Thanks,

I am trying to have a parameter for a year.
If I use a number field I get this in the prompt 2,012 for the year,  so I changed it to a string field.

I get the message "Too many arguments" on this function:
Date({?Year},1,1) <= {@SalesDate} and
{@SalesDate} <= Date({?Year},12,31)

so I tryed:
Date(ToNumber({?Year},1,1)) <= {@SalesDate} and
{@SalesDate} <= Date(ToNumber({?Year},12,31))

But still getting the same error?

Please help....
Crystal ReportsMicrosoft SQL Server 2005DB Reporting Tools

Avatar of undefined
Last Comment
Amour22015

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
peter57r

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Mike McCracken

What type is the Year parameter?

mlmcc
Amour22015

ASKER
Great that works
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23