extractEmployeeGPSRegistrationsByIDNum Method

Table of Contents

  1. Function
  2. Syntax
  3. Parameters
  4. Return Value
  5. Sample Code
  6. Remarks
  7. Possible Errors
  8. Alternate Method
  9. Related Methods

Function

  • Returns information containing an employee’s GPS activity for a specified date/time range

Syntax

  • AeEmpGeoRegistrationAry = AeXMLBridge.extractEmployeeGPSRegistrationsByIDNum(IDNum, FromDateTime, ToDateTime);

Parameters

  • String - employee ID
  • String - begin timestamp (yyyy-MM-dd HH:mm:ss.fff format)
  • String - end timestamp (yyyy-MM-dd HH:mm:ss.fff format)

Return Value

Sample Code

C#

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
string empID = "1234";                                                     
// using employee "1234"

string fromDateTime = DateTime.Now.AddDays(-100).ToString("yyyy-MM-dd HH:mm:ss.fff");
string toDateTime = DateTime.Now.ToString("yyyy-MM-dd");
// datetime does not have to have time portion to work

try
{
TAeEmpGeoRegistration[] geos = ws.extractEmployeeGPSRegistrationsByIDNum(empID, fromDateTime, toDateTime);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}

Sample Code VB.Net

1
2
3
4
5
6
7
8
9
10
11
12
Dim empID As String = "1234"
' using employee "1234"
Dim fromDateTime As String = DateTime.Now.AddDays(-100).ToString("yyyy-MM-dd HH:mm:ss.fff")

Dim toDateTime As String = DateTime.Now.ToString("yyyy-MM-dd")
' datetime does not have to have time portion to work

Try
Dim geos As TAeEmpGeoRegistration() = ws.extractEmployeeGPSRegistrationsByIDNum(empID, fromDateTime, toDateTime)
Catch ex As Exception
MessageBox.Show(ex.Message)
End Try

Remarks

  • Although the timestamp parameters can accommodate date and time within the string, you can enter date only (see sample code above)
  • Timestamp parameters must be in either yyyy-mm-dd or yyyy-mm-dd HH:mm:ss formats

Possible Errors

  • Unable to locate identifier
  • yyyy-mm-dd HH:mm:ss is required [Date Time supplied in invalid format]

Alternate Method

extractEmployeeGPSRegistrationsByFilekey

appendEmployeeGeoPunchByIDNum
appendEmployeePunchByIDNum
appendEmployeeTransferByIDNum
extractTimeClockStations
getStationsSimple
punchEmployeeGeoNowByIDNum
punchEmployeeNowByIDNum
registerEmployeeGPSPresenceByIDNum
transferEmployeeNowByIDNum

Back to Top