Share via


WorkCalendarDate::calcDefinedHours Method

Gets the number of working hours for the calendar date.

Syntax

Note

The syntax of this method varies based on the version of Microsoft Dynamics AX that you are using.

  Microsoft Dynamics AX 2012 R3
          server public static Hours calcDefinedHours(
            CalendarId _calendar, 
            TransDate _transDate, 
           [boolean _useEffectivity, 
            boolean _throwIfError, 
            CompanyId _calendarCompany])

  Microsoft Dynamics AX 2012 R2 (SYS)
          server public static Hours calcDefinedHours(
            CalendarId _calendar, 
            TransDate _transDate, 
           [boolean _useEffectivity, 
            boolean _throwIfError, 
            CompanyId _calendarCompany])

  Microsoft Dynamics AX 2012 Feature Pack (SYS)
          server public static Hours calcDefinedHours(
            CalendarId _calendar, 
            TransDate _transDate, 
           [boolean _useEffectivity, 
            boolean _throwIfError])

  Microsoft Dynamics AX 2012 (FPK)
          server public static Hours calcDefinedHours(
            CalendarId _calendar, 
            TransDate _transDate, 
           [boolean _useEffectivity, 
            boolean _throwIfError])

  Microsoft Dynamics AX 2012 (SYS)
          server public static Hours calcDefinedHours(
            CalendarId _calendar, 
            TransDate _transDate, 
           [boolean _useEffectivity, 
            boolean _throwIfError])

Run On

Server

Parameters

  • _useEffectivity
    Type: boolean
    A Boolean value that indicates whether to include the efficiency percentage in the calculation; optional.
  • _throwIfError
    Type: boolean
    A Boolean value that indicates whether to throw an error if no calendar entry was found on the date; optional.

Return Value

Type: Hours Extended Data Type
The number of working hours for the calendar date.

See Also

Reference

WorkCalendarDate Table