OP wrote:
1. How to filter records on the base of date [dd/mm/yyyy] range? The report will get two DATE parameters "fromDate" & "toDate". Can you please tell how to make this formula?
Try this
C# Crystal Reports - Date to Date [
^]
OP wrote:
2. How to filter records on the base of time [mm:hh] range? The report will get two DATE parameters "fromTime" & "toTime". Can you please tell how to make this formula?
This will help you
How to Correct this selection Formula to show time in AM or PM[
^]
This one is great
Creating Advanced Record Selection Formulas[
^](
It contains all type of things)
OP wrote:
3. I have one parameter "CompanyName" which if user provides then the data should be selected for that specific company otherwise all companies data should appear. How to create this formula?
Try this
Creating a Report with a Selection Formula[
^]
Send the selected company value to the selection formula, that's all.
OP wrote:
4. I want to create summary field which will be count of specific value lets say "XYZ" in some particular column of report. How to create such formula?
Here you go
Crystal Reports Summary Field[
^]
[Edit]
What error you are getting?
I think you need to put block() for If block.
{EMPLOYEE.BIRTHDATE} >= {?FromDate} and {EMPLOYEE.BIRTHDATE} <= {?ToDate} and
{EMPLOYEE.WORKDEPT} = {?DeptName}
Then comment the if block like above, Actually in front end(java) check the condition if DeptName has selected or not. If yes then append the DeptName thing in selection formula else stop with fromdate & todate things.
If DeptName selected then
{EMPLOYEE.BIRTHDATE} >= {?FromDate} and {EMPLOYEE.BIRTHDATE} <= {?ToDate} and
{EMPLOYEE.WORKDEPT} = {?DeptName}
else
{EMPLOYEE.BIRTHDATE} >= {?FromDate} and {EMPLOYEE.BIRTHDATE} <= {?ToDate}
Send this selection formula to report at runtime in java.
Let us know.
Pending query
Need help in Crystal Reports. (how to sum by conditions)[
^]
[/Edit]