ExceededAccrualLimit

 

Dovico.TrackITAPI.CEmployee.ExceededAccrualLimit(System.String,Dovico.TrackITAPI.CStateInfo)

 

 

Function Overview:

Call this method to determine if the accrual limit has been exceeded with time that will be submitted. Specify T for the AUTOADJUST attribute if the adjustment should be made so that the accrual rule does not exceed its imposed limit. Set EMPLOYEE to the employee ID, TASK to the accrual task you are checking for exceeding maximum hours, FROM and TO for the date range of unsubmitted time to include in the calculation.

 

 

Parameter List:

sXml - string - a string of xml containing the accrual limit to query in the format exceedaccrual.xsd

 

Returns

A string of xml containing a RESULT tag that either has a T if limit has exceeded, or an F if limit was not exceeded.

 

Example:

// build up xml to see if the employee has exceeded accrual

// for task 115 between January 1, 2000 and January 1, 2005

// with auto adjust enabled

string sXml = "<ExceedAccrual:EXCEEDACCRUAL xmlns:ExceedAccrual=\"http://www.dovico.com/schemas/exceedaccrual.xsd\" ";

sXml += "EMPLOYEE=\"100\" TASK=\"115\" FROM=\"2000-01-01T00:00:00\" ";

sXml += "TO=\"2005-01-01T00:00:00\" AUTOADJUST=\"T\"/>";

// call the EmployeeExceededAccrualLimit method

wsapi.MethodInvoke("EmployeeExceededAccrualLimit", sXml, stToken);