Home | Contact Us | Buy
Time and Attendance made easy  

 

Functions

Function Description
 AddClocking Parameters: (Date, Clocking Time, Clocking Line Time, Direction)
Adds a clocking in the processing queue. Use at the "Before Daily Processing" embed point.
Use 'I' or 'O' for the direction (including the single quotation marks).
 AddDailyHours() Adds a new daily hours record at the specified embed point for the process date and process employees. Time categoriess and employee categories can be set before adding the record, otherwise the existing processed values will be saved. When used at the embed point "At After Saving Daily Hours", a payroll record will be added. When used at the embed point "At After Saving Job Hours", a job record will be added.
ClearDailyHours() Clears the values of the existing hours record ready to be written. Use at the embed point "At After Saving Daily Hours" or "At After Saving Job Hours".
Clock Returns the current time on the PC.
CountClockings
Parameters :  (Site,Emp,FromDate,ToDate,FromTime,ToTime,Options,Area)
Counts the number of clockings for a single employee between a start point (Fromdate, Fromtime) and end point (Enddate, Endtime).

The Options field is a 3 character string where;
The first character determines the direction;
     I for In, O for Out or B for Both
The second character determines the clocking type;
     M for Manual, B for Bulk, C for Clocked, or space for all.
The third character determines the clocking scope;
     A for Access, P for Payroll or space for both

The default - "   " - (3 spaces between quotation marks) will include all options.

If the Area parameter is set, then only clockings going IN to that area will be counted.  

    The value to be used is the "Area Number"

    The default "   " (3 spaces between quotation marks) will be for all areas.

CountTime

Parameters : (Site,Emp,FromDate,ToDate,FromTime,ToTime,Options)
Counts the actual amount of raw time for a single employee between a start point (fromdate, fromtime) and end point (enddate, endtime).

The options field is a 3 character string where;
The first character determines the time being included;
     I for time In, O for time Out.
The second character determines the clocking to include;
     M for Manual, B for Bulk, C for Clocked, or space for all.
The third character determines the clocking scope;
     A for Access, P for Payroll or space for both.

 

CountTimeEx

Parameters : (Site,Emp,FromDate,ToDate,FromTime,ToTime,Options,Area)
Counts the actual amount of raw time for a single employee between a start point (fromdate, fromtime) and end point (enddate, endtime).

The options field is a 5 character string where;
The first character determines the time being included;
     I for time In, O for time Out.
The second character determines the clocking to include;
     M for Manual, B for Bulk, C for Clocked, or space for all.
The third character determines the clocking scope;
     A for Access, P for Payroll or space for both

The fourth character determines the clocking scope;
     R for Rounding to nearest minute, space for do not round

The fifth character determines the clocking scope;
     B for Break every day – apply in and out times to each date

If the Area parameter is set, then only clockings going IN to that area will be counted.  

    The value to be used is the "Area Number"

    The default "   " (3 spaces between quotation marks) will be for all areas.

Note:       CountTime is an older function that takes only 7 parameters. It is the same as CountTimeEx with the last parameter set as -1.

EmpInAt Parameters :  (Site, Emp, Date, Time)
Returns 1 if the employee is clocked in at a specific date and time. Returns 0 if the employee is clocked out. Suggested variables to use include ProcessSite, ProcessEmp and ProcessDate.
GetAverageDailyHours Parameters: (Site,Emp,FromDate,Todate,Rate,FromCat,ToCat,Step)
Gets the average daily time worked by an employee between two dates.If Rate is set blank (ie 2 single quotes '') then all rates are included. The FromCat and ToCat parameters allow you to limit the time categories included. The Step parameter allows you to skip days. For example if Fromdate is set to a Monday, and you only want to average time worked on Mondays, then set Step to 7.
GetAveragePayrollHours Parameters: (Site,Emp,FromDate,Todate,Rate,FromCat,ToCat)
Gets the average weekly time worked by an employee between two dates.If Rate is set blank (ie 2 single quotes '') then all rates are included. The FromCat and ToCat parameters allow you to limit the time categories included.
GetClockings

Parameters :  (Site,Emp,Date,FromClockNumber,ShowNumberOfClockings,ShowDeleted,LineUsed,Options,Dev)
Counts the number of clockings for a single employee for a particular date. The Options fields are;

Site – Site Name of Dataset
Emp – Employee Number
Date – date of the clockings
From Clock Number – 0 or 1 will show the clockings from the 1st clocking, etc
Show deleted – show deleted clockings in (1 – yes, 0 - no)

Line used – show clockings processed on shift line 1 to n

Options default is  ‘’     or

I = suppress in/out

M = suppress manual / bulk

D = Include 3 char device name

J = include Job Clockings

Dev - Show only clockings for this device, default for all is ‘’

 

Note:  GetClockings(site,employee,date,0,0,0,0,’’,’’) can also be used.

           GetClockings(site,employee,date,1,-1,0,0,",") returns the total clockings for the day

GetEmpDailyHours Parameters :  (Site, Emp, FromDate, ToDate, Rate, Category)
Gets the number of Daily Hours earned by an employee between two dates. If Rate is set blank (ie 2 single quotes '') then all rates are included. If the Category is left blank then all time categories are included. The answer is returned in Standard Time Format. Suggest ProcessSite, ProcessEmp and ProcessDate as relevant variables. You should not include the current ProcessDate in the date range above. However you can use dates relative to the ProcessDate, for example yesterday is ProcessDate-1.
GetEmpPayrollHours The same as GetEmpDailyHours, but gets time from the Payroll Hours.
GetExpectedHours Parameters : (Site, Employee, Date, StandardHours)
Returns the Expected Hours for that employee for that week. If a specific record for an employee exists then that is used, if not the the shift setting is used. If the shift setting is "Use Standard Hours" then  the parameter StandardHours, as passed in, is passed back to you.
IsOnLeave Parameters : (Site, Employee, Date)
Returns the Leave Type if the Employee is on leave on the date. Returns 0 otherwise. Suggest ProcessSite and ProcessEmp for the employee currently being processed. Suggest ProcessDate for the date currently being processed.
IsPublicHoliday Parameters :  (Date, State)
Returns a 1 if the date is a Public Holiday. Returns 0 otherwise. Suggest ProcessDate and emp:state for the employee currently being processed.
LineUsed Parameters : (Date)
Returns the Line used for processing, for the same employee on a different day. If you need the line currently being used on this Process Day then use UseLine.
ProcessDay Parameters : (From,To, Site, Employee)
Schedules a day, or range of days, for daily processing. Note that it only SCHEDULES the processing, it doesn't do the processing. Be careful with this that you don't cause an endless loop. 
ProcessWeek Parameters : (From,To, Site, Employee)
Schedules a week, or range of weeks, for payroll processing. Note that it only SCHEDULES the processing, it doesn't do the processing. Be careful with this that you don't cause an endless loop. 
Today Returns the current date on the PC. Use ProcessDate if you need the date currently being processed.
WriteError Parameters :  (Code, Description, Time, Type)
Allows you to write an entry to the Errors file. You can write your own error by setting the code to a number between 100 and 255. The Type should be set to 'D' for a daily error, and 'W' for a payroll shift error. The Description, and Time are available for anything you want.
WriteWarning Parameters :  (Code, Description, Time, Type)
Allows you to write an entry to the Warnings file. You can write your own warning by setting the code to a number between 100 and 255. The Type should be set to 'D' for a daily shift warning, and 'W' for a payroll shift warning. The Description, and Time are available for anything you want.

   Terms of Use      Disclaimer 

2007 CapeSoft Software (Pty) Ltd. All rights reserved.
This site is optimized for IE 6+, Firefox 1.0+, and resolution 1024*768 pix