LifespanWriter
Technical User
I had to create ReportBasic derived field macros in ReportSmith to add Derived Field result amounts to summary fields. I have them grouped and summed by pay ending date. Here are 2 examples of the ReportBasic macros I used.
This one added the hours from my “REG” derived field to the Summarized amount of hours from another derived field called, “OTHHRS”:
Sub WRKD()
REGU=VAL(SumField$("REG","Derived Field",1,"Sum"))
OTH=VAL(Field$("OTHHRS"))
TOTAL=REGU + OTH
DERIVEDFIELD STR$(TOTAL)
End Sub
This one added the earnings from my “GROSS” and “OTCODES” derived fields to the Summarized amount of earnings from other derived fields called, “GROSSA” and “GR508”:
Sub GROWAG()
GRO=VAL(Field$("GROSS")
GROA=VAL(SumField$("GROSSA","Derived Field",1,"Sum"))
GR508=VAL(SumField$("GROS508","Derived Field",1,"Sum"))
OT=VAL(Field$("OTCODES")
TOTAL=GRO - GROA - GR508 - OT
DERIVEDFIELD STR$(TOTAL)
End Sub
If it wasn’t for people who have multiple cost center salary splits (5 or more splits), I wouldn’t even have had a problem, but they are the reason why I had to do these. My problem now is that I can’t figure out how to do Sums of these Sum fields. For instance, I now want to show a count of individual’s pay ending dates (whether they are weekly or biweekly, as we have both) within the reported period, but because of both the use of the above ReportBasic macros and that I had to make sure to include hours from each individual cost center, the report counts 55 instead of what I know should be 13. I also need to be able to do a Total Sum of all paycheck earnings and an Average earnings as well, but again I’m running into the problem.
So in a nutshell, my question is, with my current settings and ReportBasic derived fields, how do I do a Count of Pay Ending Dates, a Total Earnings Sum and an Average Earnings?
Richard Sanders
Payroll/HR Systems Specialist
Lifespan Corporate Services
Providence, RI
This one added the hours from my “REG” derived field to the Summarized amount of hours from another derived field called, “OTHHRS”:
Sub WRKD()
REGU=VAL(SumField$("REG","Derived Field",1,"Sum"))
OTH=VAL(Field$("OTHHRS"))
TOTAL=REGU + OTH
DERIVEDFIELD STR$(TOTAL)
End Sub
This one added the earnings from my “GROSS” and “OTCODES” derived fields to the Summarized amount of earnings from other derived fields called, “GROSSA” and “GR508”:
Sub GROWAG()
GRO=VAL(Field$("GROSS")
GROA=VAL(SumField$("GROSSA","Derived Field",1,"Sum"))
GR508=VAL(SumField$("GROS508","Derived Field",1,"Sum"))
OT=VAL(Field$("OTCODES")
TOTAL=GRO - GROA - GR508 - OT
DERIVEDFIELD STR$(TOTAL)
End Sub
If it wasn’t for people who have multiple cost center salary splits (5 or more splits), I wouldn’t even have had a problem, but they are the reason why I had to do these. My problem now is that I can’t figure out how to do Sums of these Sum fields. For instance, I now want to show a count of individual’s pay ending dates (whether they are weekly or biweekly, as we have both) within the reported period, but because of both the use of the above ReportBasic macros and that I had to make sure to include hours from each individual cost center, the report counts 55 instead of what I know should be 13. I also need to be able to do a Total Sum of all paycheck earnings and an Average earnings as well, but again I’m running into the problem.
So in a nutshell, my question is, with my current settings and ReportBasic derived fields, how do I do a Count of Pay Ending Dates, a Total Earnings Sum and an Average Earnings?
Richard Sanders
Payroll/HR Systems Specialist
Lifespan Corporate Services
Providence, RI