UpdateUtilReason(Int32,String,Int32,Int32,Boolean,Boolean,Boolean,Boolean,Boolean,String,String,Int32,Nullable<DateTime>) Method
- Last UpdatedNov 06, 2025
- 2 minute read
The UpdateUtilReason() method updates the data of the specified utilization reason. This overload of the method uses an integer to specify the reason code and includes a lastEditAt DateTime parameter that can be used for optimistic concurrency control.
'Declaration
Public Overloads Shared Function UpdateUtilReason( _
ByVal reasCD As Integer, _
ByVal reasDesc As String, _
ByVal reasonGrpID As Integer, _
ByVal stateCD As Integer, _
ByVal runTime As Boolean, _
ByVal downTime As Boolean, _
ByVal setupTime As Boolean, _
ByVal teardownTime As Boolean, _
ByVal fixedTime As Boolean, _
ByVal varTime As String, _
ByVal defLabCD As String, _
ByVal displaySeq As Integer, _
ByVal lastEditAt As Nullable(Of Date) _
) As Date
public static DateTime UpdateUtilReason(
int reasCD,
string reasDesc,
int reasonGrpID,
int stateCD,
bool runTime,
bool downTime,
bool setupTime,
bool teardownTime,
bool fixedTime,
string varTime,
string defLabCD,
int displaySeq,
Nullable<DateTime> lastEditAt
)
Parameters
- reasCD
- Required. Holds the reason code.
- reasDesc
- Required. Holds the description.
- reasonGrpID
- Required. Holds the group ID.
- stateCD
- Required. Holds the state code.
- runTime
Required. Holds a value indicating whether the utilization reason counts toward runtime events (acts as a boolean).
- downTime
Required. Holds a value indicating whether the utilization reason counts toward downtime events (acts as a boolean).
- setupTime
Required. Holds a value indicating whether the utilization reason counts toward setup time events (acts as a boolean).
- teardownTime
Required. Holds a value indicating whether the utilization reason counts toward teardown time events (acts as a boolean).
- fixedTime
Required. Holds a value indicating whether the utilization reason counts toward fixed time events (acts as a boolean).
- varTime
Required. Holds a value indicating whether the utilization reason counts toward variable time events (acts as a boolean).
- defLabCD
- Required. Holds the default labor code to be used for the utilization reason being updated. This may be an empty string.
- displaySeq
- Required. Holds the utilization reason's display sequence number.
- lastEditAt
- Optional. Holds the date/time value that can be used to avoid data contention. If it is specified, the value must match that value in the database in order for the update to succeed.