Update Method (PO)
- Last UpdatedNov 06, 2025
- 2 minute read
The Update() method updates all columns of the specified purchase order record in the PO table.
The purchase order is uniquely identified by the purchase order ID in the purchase order record.
'Declaration
Public Shared Sub Update( _
ByVal sessionId As Integer, _
ByVal poId As String, _
ByVal vendId As DBString, _
ByVal sellerId As DBInt, _
ByVal shipTo As DBInt, _
ByVal dateIssuedLocal As Date, _
ByVal stateCode As PurchaseOrderState, _
ByVal notes As DBString, _
ByVal spare1 As DBString, _
ByVal spare2 As DBString, _
ByVal spare3 As DBString, _
ByVal spare4 As DBString, _
ByVal lastEditComment As DBString, _
ByVal lastEditAt As Date _
)
'Usage
Dim sessionId As Integer
Dim poId As String
Dim vendId As DBString
Dim sellerId As DBInt
Dim shipTo As DBInt
Dim dateIssuedLocal As Date
Dim stateCode As PurchaseOrderState
Dim notes As DBString
Dim spare1 As DBString
Dim spare2 As DBString
Dim spare3 As DBString
Dim spare4 As DBString
Dim lastEditComment As DBString
Dim lastEditAt As Date
PO.Update(sessionId, poId, vendId, sellerId, shipTo, dateIssuedLocal, stateCode, notes, spare1, spare2, spare3, spare4, lastEditComment, lastEditAt)
public static void Update(
int sessionId,
string poId,
DBString vendId,
DBInt sellerId,
DBInt shipTo,
DateTime dateIssuedLocal,
PurchaseOrderState stateCode,
DBString notes,
DBString spare1,
DBString spare2,
DBString spare3,
DBString spare4,
DBString lastEditComment,
DateTime lastEditAt
)
Parameters
- sessionId
- Required. Holds the session ID and thus the user who is making this method call.
- poId
- Required. Holds the ID of the purchase order.
- vendId
- Required. Holds the ID of the vendor for the purchase order.
- sellerId
- Required. Holds the ID of the seller from whom the order was purchased.
- shipTo
- Required. Holds the ID of the entity at which purchased goods are to be received.
- dateIssuedLocal
- Required. Holds the date the purchase order was issued in the local time of the entity specified by the shipTo parameter, if supplied. If a ship-to entity is not specified, the default time zone will be used to determine the local time.
- stateCode
Required. Holds a PurchaseOrderState enumeration value that indicates the state of the purchase order:
0=Open (the default)
1=Partially Complete
2=Complete
3=Closed
- notes
- Required. Holds notes about the purchase order.
- spare1
- Required. Holds the contents of the user-defined spare1 field.
- spare2
- Required. Holds the contents of the user-defined spare2 field.
- spare3
- Required. Holds the contents of the user-defined spare3 field.
- spare4
- Required. Holds the contents of the user-defined spare4 field.
- lastEditComment
- Required. Holds comments that describe why this record is being added.
- lastEditAt
Required. Holds the date/time when this record was added or last edited, for optimistic concurrency control. The passed value must match the lastEditAt value in the record for the update to succeed.
Output. Holds the date/time value when this record was updated by this called method.