UpdateSpecific Method (UserName)
- Last UpdatedNov 06, 2025
- 3 minute read
The UpdateSpecific() method updates selected columns of the specified user name record in the User_Name table.
'Declaration
Public Shared Sub UpdateSpecific( _
ByVal sessionId As Integer, _
ByVal userId As String, _
ByVal userDesc As DBString, _
ByVal active As Nullable(Of Boolean), _
ByVal hourlyCost As DBDouble, _
ByVal langId As Nullable(Of Integer), _
ByVal defaultDeptId As DBString, _
ByVal authMethod As Nullable(Of Integer), _
ByVal defaultLabCd As DBString, _
ByVal spare1 As DBString, _
ByVal spare2 As DBString, _
ByVal spare3 As DBString, _
ByVal spare4 As DBString, _
ByVal lastEditComment As DBString, _
ByVal modId As String, _
ByRef lastEditAt As Date _
)
'Usage
Dim sessionId As Integer
Dim userId As String
Dim userDesc As DBString
Dim active As Nullable(Of Boolean)
Dim hourlyCost As DBDouble
Dim langId As Nullable(Of Integer)
Dim defaultDeptId As DBString
Dim authMethod As Nullable(Of Integer)
Dim defaultLabCd As DBString
Dim spare1 As DBString
Dim spare2 As DBString
Dim spare3 As DBString
Dim spare4 As DBString
Dim lastEditComment As DBString
Dim modId As String
Dim lastEditAt As Date
UserName.UpdateSpecific(sessionId, userId, userDesc, active, hourlyCost, langId, defaultDeptId, authMethod, defaultLabCd, spare1, spare2, spare3, spare4, lastEditComment, modId, lastEditAt)
public static void UpdateSpecific(
int sessionId,
string userId,
DBString userDesc,
Nullable<bool> active,
DBDouble hourlyCost,
Nullable<int> langId,
DBString defaultDeptId,
Nullable<int> authMethod,
DBString defaultLabCd,
DBString spare1,
DBString spare2,
DBString spare3,
DBString spare4,
DBString lastEditComment,
string modId,
ref DateTime lastEditAt
)
Parameters
- sessionId
Required. Holds the session ID and thus the user who is making this method call.
- userId
Required. Holds the ID of the user. For example, the employee number or name of the employee.
- userDesc
Optional. Holds the description for the user. For example, the name of the employee.
- active
Optional. Holds a flag that, if set to true, specifies that the state of the user is active in the MES system.
- hourlyCost
- Optional. Holds the cost of the labour per hour.
- langId
- Optional. Holds the ID of the user's preferred language.
- defaultDeptId
- Optional. Holds the default department ID of the user.
- authMethod
- Optional. Holds the authentication method. The value 0 indicates "Internal" and 1 indicates "Windows (future)".
- defaultLabCd
- Optional. Holds the default labor code of the user.
- spare1
- Optional. Holds the contents of the user-defined spare1 field.
- spare2
- Optional. Holds the contents of the user-defined spare2 field.
- spare3
- Optional. Holds the contents of the user-defined spare3 field.
- spare4
- Optional. Holds the contents of the user-defined spare4 field.
- lastEditComment
- Optional. Holds comments that describe why this record is being updated.
- modId
Required. Holds the modification ID assigned the last time this record was added or last updated, for optimistic concurrency control. The passed value must match the record's modId for the record to be updated.
Output. Holds the new modification ID to identify this update of this record.
- lastEditAt
Optional. Holds the date/time when this record was added or last updated, for optimistic concurrency control. If it is specified, the passed value must match the lastEditAt value in the record for the update to succeed.
Output. Holds the date/time value when the record was updated by this called method.
Observe the following input parameter rules:
- Optional non-DB* parameters: Either enter a new value or leave the existing value unchanged by passing a null.
- Optional DB* parameters: To clear the existing value and enter an empty value, pass DB*.null (e.g., DBInt.null). To leave the existing value unchanged, pass a null.